librelist archives

« back to archive

About minimum window size.

About minimum window size.

From:
Satoshi Asakawa
Date:
2010-04-25 @ 10:00
Hi all,

I realized a difference between Raisins and Policeman for Windows about
window-resizing-behavior.

  # test1.rb
  Shoes.app{}

  # test2.rb
  Shoes.app(:width=>300, :height=>300){}

  # test3.rb
  Shoes.app(:width=>300){}

Raisins can always resize window size smaller.
Policeman can resize window size smaller in test1 but can't in test2.
Policeman can resize window height size smaller but can't resize window
width size smaller in test3.

I found this git commit: 100f158275c739efc71c4f8e7543b367813f269f

_why added `app->minwidth` and `app->minheight` in the shoes/app.c.
His commit comment is:

  * shoes/app.c: minimum window size for osx and windows, to match gtk's
behavior.

Umm... is this Unix's (gtk's) behavior?
Even so, is it necessary `to match`?

ashbb

Re: [shoes] About minimum window size.

From:
i5m
Date:
2010-05-17 @ 22:16
ashbb,

Now I've got OSX PPC working properly I'll try to catch-up with some of your
emails each day.


On Sun, Apr 25, 2010 at 11:00 AM, Satoshi Asakawa <ashbbb@gmail.com> wrote:

> Hi all,
>
> I realized a difference between Raisins and Policeman for Windows about
> window-resizing-behavior.
>
>   # test1.rb
>   Shoes.app{}
>
>   # test2.rb
>   Shoes.app(:width=>300, :height=>300){}
>
>   # test3.rb
>   Shoes.app(:width=>300){}
>
> Raisins can always resize window size smaller.
> Policeman can resize window size smaller in test1 but can't in test2.
> Policeman can resize window height size smaller but can't resize window
> width size smaller in test3.
>
> Umm... is this Unix's (gtk's) behavior?
> Even so, is it necessary `to match`?
>
> ashbb
>

OSX PPC, Shoes Policeman is the same as you describe. This feels correct to
me. I.e. min width and heights should be minimums. I.e. Shoes 3 = good,
Shoes 2 = bad.

Now you've got Linux working I'm sure you've answered your (GTK) question,
but thought I'd just say what OSX does.

Re: [shoes] About minimum window size.

From:
Satoshi Asakawa
Date:
2010-05-18 @ 15:09
Hi i5m et al,

> Now I've got OSX PPC working properly
Wow, god news. So cool!

Thank you for letting me know about Policeman OSX behavior.
I could know Policeman had the same behavior on all three platforms.

But, how can I do when I want to resize window size smaller?

I suggest to add :minwidth/:minheight/:maxwidth/:maxheight options.
How about the following spec?

#1
Shoes.app(:width=>300){}
#=> It opens the 300pix width size window.
#   Then you can resize both smaller and bigger.

#2
Shoes.app(:minwidth=>300){}
#=> It opens the 300pix width size window.
#   Then you can resize bigger only (minimum width size is 300)

#3
Shoes.app(:maxwidth=>300){}
#=> It opens the 300pix width size window.
#   Then you can resize smaller only (maximum width size is 300)

ashbb

Re: [shoes] About minimum window size.

From:
i5m
Date:
2010-05-18 @ 23:12
Ashbb,

On 18 May 2010, at 16:09, Satoshi Asakawa <ashbbb@gmail.com> wrote:

> But, how can I do when I want to resize window size smaller?
>
> I suggest to add :minwidth/:minheight/:maxwidth/:maxheight options.
> How about the following spec?

Good idea. For Shoes 4 (Mustard)?

Re: [shoes] About minimum window size.

From:
ashbb
Date:
2010-07-21 @ 14:46
Hi all,

I tried to debug a little for :minwidth and :minheight options.

Because I did this discussion on Hackety Hack ML:
http://librelist.com/browser//hacketyhack/2010/7/19/main-window-size/

Now, :minwidth and :minheight seems to work fine on my Windows XP.
Look at this spec (commit):
http://github.com/ashbb/shoes/commit/9a8b0e44c5177916649000ffa916361617fd941a

and confirm on your computer, especially on Mac please. ;-)

Cheers,
ashbb

Re: [shoes] About minimum window size.

From:
Cecil Coupe
Date:
2010-07-22 @ 01:50
Works fine on Linux using this little test script:

Shoes.app(:width=>300, :minwidth=>200, :minheight=>200) do
    stack do
      para "Really long line to see what happens to minwidth"
      para "Plus some buttons for height"
      button "One"
      button "Two"
      button "Three"
      button "Four"
      para "Last widget on the screen is this para"
    end
end

--Cecil

On Wed, 2010-07-21 at 23:46 +0900, ashbb wrote:
> Hi all,
> 
> I tried to debug a little for :minwidth and :minheight options.
> 
> Because I did this discussion on Hackety Hack ML:
> http://librelist.com/browser//hacketyhack/2010/7/19/main-window-size/
> 
> Now, :minwidth and :minheight seems to work fine on my Windows XP.
> Look at this spec (commit):
> http://github.com/ashbb/shoes/commit/9a8b0e44c5177916649000ffa916361617fd941a
> 
> and confirm on your computer, especially on Mac please. ;-)
> 
> Cheers,
> ashbb
> 
> 

Re: [shoes] About minimum window size.

From:
ashbb
Date:
2010-07-22 @ 12:50
Cecil,

Wow, good news! Thank you for taking your time. :)

ashbb