|
csflwlay.h00001 /* 00002 Copyright (C) Aleksandras Gluchovas 00003 CS port by Norman Krämer <norman@users.sourceforge.net> 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public 00016 License along with this library; if not, write to the Free 00017 Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00018 */ 00019 00020 #ifndef __FLOWLAYOUT_G__ 00021 #define __FLOWLAYOUT_G__ 00022 00023 #include "cslayout.h" 00024 00053 class csFlowLayout : public csLayout 00054 { 00055 protected: 00056 int mAlign; 00057 int mHgap; 00058 int mVgap; 00059 00060 csPoint mPrefDimOfPhase1; 00061 public: 00066 csFlowLayout (csComponent *pParent); 00067 csFlowLayout (csComponent *pParent, int align); 00068 csFlowLayout (csComponent *pParent, int align, int hgap, int vgap); 00069 00071 int GetAlignment (); 00073 int GetHgap (); 00075 int GetVgap (); 00076 00078 void SetAlignment (int align); 00080 void SetHgap (int hgap); 00082 void SetVgap (int vgap); 00083 00084 // impl. of LayoutManager interface 00085 00086 virtual void SuggestSize (int &sugw, int& sugh); 00087 00088 virtual void LayoutContainer (); 00089 00090 public: 00091 00092 enum ALIGNMNET_ENUM 00093 { 00098 CENTER = 0, 00099 LEFT = 1, 00100 RIGHT = 2, 00101 00102 LEADING = LEFT, // for Western, Europian text-orientation 00103 TRAILING = RIGHT // -/- 00104 }; 00105 }; 00106 00107 #endif // __FLOWLAYOUT_G__ Generated for Crystal Space by doxygen 1.2.5 written by Dimitri van Heesch, ©1997-2000 |