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