[haiku-development] Re: AddGlue() as a metaphor behaves opposite what is expected

  • From: Jérôme Duval <jerome.duval@xxxxxxxxx>
  • To: haiku-development <haiku-development@xxxxxxxxxxxxx>
  • Date: Sat, 25 Feb 2017 15:55:49 +0100

Am 25.02.2017 3:16 nachm. schrieb "Brian Hill" <brianh@xxxxxxxxxxxx>:

This may be a slight rant but I am always struggling with remembering the
proper use of the layout builder AddGlue() function.  It exhibits a totally
opposite behavior from real life glue, which is used to stick two things
together so they do not separate.  AddGlue() does the opposite, adds an
expandable space layout item so the two things you stick the AddGlue() to
can move apart.


Java Swing uses the same word so it must not be completely wrong.

https://docs.oracle.com/javase/tutorial/uiswing/layout/box.html#glue

Bye,
Jerome

Other related posts: