* Add new spacing/inset constants for the layout API. For now, leave B_USE_DEFAULT_SPACING, but this will go soon.

* Rename BControlLook::ComposeItemSpacing() to ComposeSpacing(), and extend it to handle the new constants.
* Adjust users of BControlLook::ComposeItemSpacing() accordingly.
* part of #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42025 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Alex Wilson
2011-06-07 20:40:56 +00:00
parent 0bae414087
commit 6648dd3cf1
7 changed files with 47 additions and 23 deletions
+2 -1
View File
@@ -79,7 +79,8 @@ public:
/* TODO: virtual*/
float DefaultItemSpacing() const;
static float ComposeItemSpacing(float spacing);
static float ComposeSpacing(float spacing);
uint32 Flags(BControl* control) const;
+17 -1
View File
@@ -223,7 +223,23 @@ enum vertical_alignment {
B_ALIGN_USE_FULL_HEIGHT = -2L
};
const float B_USE_DEFAULT_SPACING = -2.0f;
// Layout spacing and insets, see BControlLook::ComposeSpacing()
enum {
B_USE_DEFAULT_SPACING = -2,
B_USE_ITEM_SPACING = -2,
B_USE_ITEM_INSETS = -2,
B_USE_HALF_ITEM_SPACING = -3,
B_USE_HALF_ITEM_INSETS = -3,
B_USE_WINDOW_INSETS = -4,
B_USE_WINDOW_SPACING = -4,
B_USE_SMALL_INSETS = -5,
B_USE_SMALL_SPACING = -5,
B_USE_BIG_INSETS = -6,
B_USE_BIG_SPACING = -6
};
// Line join and cap modes