History log of /haiku-fatelf/headers/os/interface/MenuField.h
Revision Date Author Comments
# d56e7bd6 01-Dec-2011 Alex Wilson <yourpalal2@gmail.com>

Make archiving hooks protected in layout classes.

Furthermore,
* remove a stray blank line in Layout.cpp
* make BLayoutItem::SetLayout() private, as it should have been


# 61eb1f1d 22-Oct-2011 Alex Wilson <yourpalal2@gmail.com>

Replace remaining InvalidateLayout()'s with LayoutInvalidated(). Also do a bit of cleanup/move methods around.


# 4296233f 06-May-2011 Axel Dörfler <axeld@pinc-software.de>

* Made the messed up BMessage* constructors private - since it only affects the
layout API, we probably can just phase it out after a while.
* Introduced new constructors, and added missing flags to one of them to make
it more convenient to use.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41350 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7a37b89b 27-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Updated BMenuField and its custom BLayoutItems for layout-safe archiving. Added an _InitMenu(const BMessage*) method that inits the menu during unarchival.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37778 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 75a6d1db 26-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

Optimized includes. For example, BeBuild.h is almost always already included
via SupportDefs.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32748 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 89208c77 27-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

Finished unifying the Interface Kit headers:
* Fixed copyrights (puncuation and capitalization, removed authors from
headers)
* Updated indentation style
* Unified pointer/reference style
* Re-ordered some methods for better grouping where it could be done
(abd adopted source accordingly)
* Small coding style fixes here and there

No functional change intended.

+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32745 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a449ca33 26-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

* Updated indentation style
* Fixed copyright

+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 12194e33 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Added missing default initializer for the message.
* Changed BMenuField::MenuBarLayoutItem::BasePreferredSize() to return the
min size as well, instead of a fixed 100 pixels for the width...
* More minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32177 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 50f8cd14 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Cleanup, no functional change.
* Remove superfluous operator=() implementations.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32174 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 47e745c6 22-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

* Fixed the unified menu bar width calculations. SetDivider() got it wrong.
* _InitMenuBar() had the meaning of fixedSize reversed. The layout-mode
constructors pass fixedSize = true accordingly.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29664 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cda78e4f 23-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

Fixed more inconsistencies in layouting the menu bar. These would mostly
result in the BMenuField not always drawing all of the frame around the
menu bar correctly, for example cutting off at left for divider = 0.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29660 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 08edea66 16-Sep-2008 Stephan Aßmus <superstippi@gmx.de>

* Don't set an explicit max size, instead calculate a proper max size in
MaxSize(). This makes sure that MaxSize() returns a proper size when the
user "unsets" the explicite max size.
* minimum label height is 0 if there is no label.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27583 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 14f63456 14-Sep-2008 Stephan Aßmus <superstippi@gmx.de>

Several fixes to BMenuField layout calculations.
* The most important fix is that in BMenuField::_ValidateLayoutData(),
divider was calculated, but then never used. If the menu field was not
using the layout management, it should take the existing fDivider into
account, but never did. This caused #2728.
* Added some tracing that helped me debug this.
* Fixed a bunch of layouting inconsistencies. It will also improve some
unnecessary resizing of the menu bar.

Will test all of this some more. But in the test app I do have, the BMenuField
works more like in BeOS now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27508 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ee70f30e 19-Nov-2007 Stefano Ceccherini <stefano.ceccherini@gmail.com>

cleanups


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22965 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b321303c 19-Jun-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

* Implemented Min/Max/PreferredSize().
* Reworked the internal layout. _ValidateLayoutData() computes and caches the
layout related data and all other methods just use those values. Now, in
layout-aware mode the class should properly work not only when using the
layout items. And when using layout items, the class does actually do
internal layout; it was basically good luck that it worked in the tests,
before. Vertical resizing is supported, too.
* We do a few mean tricks to get the probably mostly preferred layout behavior:
By default our own explicit max width and that of the menu bar layout item is
set to unlimited and the horizontal menu bar alignment to left aligned. This
allows to horizontally resize a BMenuField beyond its preferred size,
although both label and menu bar have a limited max width. The user can, of
course, override those explicit sizes/alignments to get a different behavior,
if desired.
* Fixed invalidation in SetDivider(). When having the focus, the left and top
border of the blue frame were not invalidated.
* The label is no longer drawn at vertical position font ascent + descent
+ leading + 2 (not sure how this calculation was supposed to work), but
vertically centers the label around the ascent. With big fonts the label is
shown a bit too far to the bottom. Not sure how to fix this in a generic way.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21466 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9ecf9d1c 26-Aug-2006 Ingo Weinhold <ingo_weinhold@gmx.de>

Merge from layout management branch.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18649 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d734a8ce 23-Oct-2002 beveloper <beveloper@nowhere.fake>

some header files to be R5 compatible


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1617 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d56e7bd64d975565dbdd2c38230b6f14eb3e5906 01-Dec-2011 Alex Wilson <yourpalal2@gmail.com>

Make archiving hooks protected in layout classes.

Furthermore,
* remove a stray blank line in Layout.cpp
* make BLayoutItem::SetLayout() private, as it should have been


# 61eb1f1d19eed26b6138b0701612e8eb31bb1d86 22-Oct-2011 Alex Wilson <yourpalal2@gmail.com>

Replace remaining InvalidateLayout()'s with LayoutInvalidated(). Also do a bit of cleanup/move methods around.


# 4296233f0e47fd8f99f86fde3aba51d7b9cdd8c3 06-May-2011 Axel Dörfler <axeld@pinc-software.de>

* Made the messed up BMessage* constructors private - since it only affects the
layout API, we probably can just phase it out after a while.
* Introduced new constructors, and added missing flags to one of them to make
it more convenient to use.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41350 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7a37b89be9f81088d05ea085a099816ec16e7095 27-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Updated BMenuField and its custom BLayoutItems for layout-safe archiving. Added an _InitMenu(const BMessage*) method that inits the menu during unarchival.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37778 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 75a6d1db99fe8ea432c7ff8d80cfc095710d02f5 26-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

Optimized includes. For example, BeBuild.h is almost always already included
via SupportDefs.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32748 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 89208c77f10235d43fda0c7b3fd6751db02cc12c 27-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

Finished unifying the Interface Kit headers:
* Fixed copyrights (puncuation and capitalization, removed authors from
headers)
* Updated indentation style
* Unified pointer/reference style
* Re-ordered some methods for better grouping where it could be done
(abd adopted source accordingly)
* Small coding style fixes here and there

No functional change intended.

+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32745 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a449ca33dc4543dced8e509f41fe15be078d1722 26-Aug-2009 Stephan Aßmus <superstippi@gmx.de>

* Updated indentation style
* Fixed copyright

+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 12194e33b720dd4785c9ca34e06b807d91c36566 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Added missing default initializer for the message.
* Changed BMenuField::MenuBarLayoutItem::BasePreferredSize() to return the
min size as well, instead of a fixed 100 pixels for the width...
* More minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32177 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 50f8cd14bb40895f9167f44752525386af219513 07-Aug-2009 Axel Dörfler <axeld@pinc-software.de>

* Cleanup, no functional change.
* Remove superfluous operator=() implementations.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32174 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 47e745c6db828c73ebfca60c7cd353fcf2ed7a99 22-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

* Fixed the unified menu bar width calculations. SetDivider() got it wrong.
* _InitMenuBar() had the meaning of fixedSize reversed. The layout-mode
constructors pass fixedSize = true accordingly.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29664 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cda78e4f8e852651f5cc079016b3fd5513769e92 23-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

Fixed more inconsistencies in layouting the menu bar. These would mostly
result in the BMenuField not always drawing all of the frame around the
menu bar correctly, for example cutting off at left for divider = 0.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29660 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 08edea662badba1b3ef30ad22414e53de28beca8 16-Sep-2008 Stephan Aßmus <superstippi@gmx.de>

* Don't set an explicit max size, instead calculate a proper max size in
MaxSize(). This makes sure that MaxSize() returns a proper size when the
user "unsets" the explicite max size.
* minimum label height is 0 if there is no label.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27583 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 14f6345690030316dbb45d1f4f51ade879bc86ab 14-Sep-2008 Stephan Aßmus <superstippi@gmx.de>

Several fixes to BMenuField layout calculations.
* The most important fix is that in BMenuField::_ValidateLayoutData(),
divider was calculated, but then never used. If the menu field was not
using the layout management, it should take the existing fDivider into
account, but never did. This caused #2728.
* Added some tracing that helped me debug this.
* Fixed a bunch of layouting inconsistencies. It will also improve some
unnecessary resizing of the menu bar.

Will test all of this some more. But in the test app I do have, the BMenuField
works more like in BeOS now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27508 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ee70f30ea0f1ff2fb6c47b41ae87227c9c46c89e 19-Nov-2007 Stefano Ceccherini <stefano.ceccherini@gmail.com>

cleanups


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22965 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b321303cf9862de9ef3f5526d78c5c317cfc45e4 19-Jun-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

* Implemented Min/Max/PreferredSize().
* Reworked the internal layout. _ValidateLayoutData() computes and caches the
layout related data and all other methods just use those values. Now, in
layout-aware mode the class should properly work not only when using the
layout items. And when using layout items, the class does actually do
internal layout; it was basically good luck that it worked in the tests,
before. Vertical resizing is supported, too.
* We do a few mean tricks to get the probably mostly preferred layout behavior:
By default our own explicit max width and that of the menu bar layout item is
set to unlimited and the horizontal menu bar alignment to left aligned. This
allows to horizontally resize a BMenuField beyond its preferred size,
although both label and menu bar have a limited max width. The user can, of
course, override those explicit sizes/alignments to get a different behavior,
if desired.
* Fixed invalidation in SetDivider(). When having the focus, the left and top
border of the blue frame were not invalidated.
* The label is no longer drawn at vertical position font ascent + descent
+ leading + 2 (not sure how this calculation was supposed to work), but
vertically centers the label around the ascent. With big fonts the label is
shown a bit too far to the bottom. Not sure how to fix this in a generic way.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21466 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9ecf9d1c1d4888d341a6eac72112c72d1ae3a4cb 26-Aug-2006 Ingo Weinhold <ingo_weinhold@gmx.de>

Merge from layout management branch.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18649 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d734a8ce5a83e48e17a2d0d6635090d48c5ad161 23-Oct-2002 beveloper <beveloper@nowhere.fake>

some header files to be R5 compatible


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1617 a95241bf-73f2-0310-859d-f6bbb57e9c96