1/* 2 * Copyright 2020 Haiku, Inc. All rights reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Niels Sascha Reedijk, niels.reedijk@gmail.com 7 * 8 * Corresponds to: 9 * headers/os/interface/GroupView.h hrev45833 10 * src/kits/interface/GroupView.cpp hrev49977 11 */ 12 13 14/*! 15 \file GroupView.h 16 \ingroup interface 17 \brief Provides the BGroupView class. 18 19 \since Haiku R1 20*/ 21 22 23/*! 24 \class BGroupView 25 \ingroup interface 26 \ingroup libbe 27 \brief Container view for a collection of views organized in a horizontal 28 or vertical row. 29 30 The group has a horizontal or a vertical orientation. By default, the view 31 has the default system grey background. 32 33 \see BGroupLayout for more information on how and when to use this 34 type of container. 35 36 \since Haiku R1 37*/ 38 39 40/*! 41 \fn BGroupView::BGroupView(orientation orientation, float spacing) 42 \brief Creates a new group view. 43 44 \param orientation Set to B_HORIZONTAL or B_VERTICAL. 45 \param spacing The space between the elements in the group. 46 47 \since Haiku R1 48*/ 49 50 51/*! 52 \fn BGroupView::BGroupView(const char *name, orientation orientation, 53 float spacing) 54 \brief Creates a new group view with a \a name. 55 56 \param name The name for the view. 57 \param orientation Set to B_HORIZONTAL or B_VERTICAL. 58 \param spacing The space between the elements in the group. 59 60 \since Haiku R1 61*/ 62 63 64/*! 65 \fn BGroupView::BGroupView(BMessage *from) 66 \brief Constructs a BGroupView \a from an archive message. 67 68 This method is usually not called directly, if you want to build a 69 group view from an archived message you should call Instantiate() instead 70 because it can handle errors properly. 71 72 \param from The \ref BMessage that contains the grid view. 73 74 \since Haiku R1 75*/ 76 77 78/*! 79 \fn virtual BGroupView::~BGroupView() 80 \brief Destructor. 81 82 \since Haiku R1 83*/ 84 85 86/*! 87 \fn virtual void BGroupView::SetLayout(BLayout *layout) 88 \brief Adopt a given group \a layout. 89 90 \param layout The layout to set to. This must be a BGroupLayout, or a 91 derivative. Any other layout types will be ignored. 92 93 \since Haiku R1 94*/ 95 96 97/*! 98 \fn BGroupLayout* BGroupView::GroupLayout() const 99 \brief Get a pointer to the underlying BGroupLayout. 100 101 \return A pointer to the underlying group layout. 102 103 \since Haiku R1 104*/ 105 106 107/*! 108 \fn virtual status_t BGroupView::Perform(perform_code d, void *arg) 109 \brief Perform some action. (Internal Method) 110 111 Reimplemented from BView::Perform() 112 113 \since Haiku R1 114*/ 115 116 117/*! 118 \fn static BArchivable* BGroupView::Instantiate(BMessage *from) 119 \brief Instantiate the view from the message \a from. 120 121 \since Haiku R1 122*/ 123