1/* 2 * Copyright 2010 Haiku, Inc. All rights reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Alex Wilson, yourpalal2@gmail.com 7 * 8 * Corresponds to: 9 * headers/os/interface/AbstractLayout.h rev 39055 10 * src/kits/inteface/AbstractLayout.cpp rev 39055 11 */ 12 13 14/*! 15 \class BAbstractLayout 16 \ingroup layout 17 \ingroup libbe 18 \brief BLayout subclass providing convenience methods for derived 19 implementations. 20 \since Haiku R1 21 22 This class is designed to reduce the amount of boilerplate code required to 23 write a BLayout subclass. In most cases, you classes should derive from 24 BAbstractLayout rather than BLayout. 25 26 When a BAbstractLayout is attached to a BView, many of the methods provided 27 by the BAbstractLayout class are forwarded to the BAbstractLayout's 28 owner BView. When a BAbstractLayout is viewless, these methods are handled 29 locally. 30 31 \warning This class is not yet finalized, if you use it in your software 32 assume that it will break some time in the future. 33*/ 34 35 36/*! 37 \name Constructors 38 39 @{ 40*/ 41 42 43/*! 44 \fn BAbstractLayout::BAbstractLayout() 45 \brief Construct a BAbstractLayout. 46 47 \since Haiku R1 48*/ 49 50 51/*! 52 \fn BAbstractLayout::BAbstractLayout(BMessage* from); 53 \brief Archive constructor. 54 55 \since Haiku R1 56*/ 57 58 59//! @} 60 61 62/*! 63 \fn BSize BAbstractLayout::MinSize() 64 \copydoc BLayoutItem::MinSize() 65 \since Haiku R1 66 67 The return value for this method is composed (using 68 BLayoutUtils::ComposeSize()) from the values returned by BaseMinSize() and 69 ExplicitMinSize(). 70*/ 71 72 73/*! 74 \fn BSize BAbstractLayout::MaxSize() 75 \copydoc BLayoutItem::MaxSize() 76 77 The return value for this method is composed (using 78 BLayoutUtils::ComposeSize()) from the values returned by BaseMaxSize() and 79 ExplicitMaxSize(). 80 81 \since Haiku R1 82*/ 83 84 85/*! 86 \fn BSize BAbstractLayout::PreferredSize() 87 \copydoc BLayoutItem::PreferredSize() 88 89 The return value for this method is composed (using 90 BLayoutUtils::ComposeSize()) from the values returned by BasePreferredSize() 91 and ExplicitPreferredSize(). 92 93 \since Haiku R1 94*/ 95 96 97/*! 98 \fn BAlignment BAbstractLayout::Alignment() 99 \copydoc BLayoutItem::Alignment() 100 101 The return value for this method is composed (using 102 BLayoutUtils::ComposeAlignment()) from the values returned by 103 BaseAlignment() and ExplicitAlignment() 104 105 \since Haiku R1 106*/ 107 108 109/*! 110 \name Hook Methods 111 112 @{ 113*/ 114 115 116/*! 117 \fn BSize BAbstractLayout::BaseMinSize() 118 \brief Method to be implemented in derived classes return the minimum size 119 constraint for this BAbstractLayout. 120 121 \since Haiku R1 122*/ 123 124 125/*! 126 \fn BSize BAbstractLayout::BaseMaxSize() 127 \brief Method to be implemented in derived classes return the maximum size 128 constraint for this BAbstractLayout. 129 130 \since Haiku R1 131*/ 132 133 134/*! 135 \fn BSize BAbstractLayout::BasePreferredSize() 136 \brief Method to be implemented in derived classes return the preferred size 137 constraint for this BAbstractLayout. 138 139 \since Haiku R1 140*/ 141 142 143/*! 144 \fn BAlignment BAbstractLayout::BaseAlignment() 145 \brief Method to be implemented in derived classes return the preferred 146 alignment for this BAbstractLayout. 147*/ 148 149 150//! @} 151