mirror of
https://review.haiku-os.org/haiku
synced 2025-01-30 18:24:53 +01:00
a101e99aad
BLayout implementation (BALMLayout) using the Auckland Layout Model (ALM). The original ALM was implemented by Christof Lutteroth, the Haiku/C++ version by James Kim. The code needs some review, but the test programs seem to work fine. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23889 a95241bf-73f2-0310-859d-f6bbb57e9c96
59 lines
979 B
C++
59 lines
979 B
C++
#ifndef COLUMN_H
|
|
#define COLUMN_H
|
|
|
|
#include "Constraint.h"
|
|
|
|
#include <List.h>
|
|
|
|
|
|
namespace BALM {
|
|
|
|
class BALMLayout;
|
|
class XTab;
|
|
|
|
/**
|
|
* Represents a column defined by two x-tabs.
|
|
*/
|
|
class Column {
|
|
|
|
public:
|
|
XTab* Left() const;
|
|
XTab* Right() const;
|
|
Column* Previous() const;
|
|
void SetPrevious(Column* value);
|
|
Column* Next() const;
|
|
void SetNext(Column* value);
|
|
//~ string ToString();
|
|
void InsertBefore(Column* column);
|
|
void InsertAfter(Column* column);
|
|
Constraint* HasSameWidthAs(Column* column);
|
|
BList* Constraints() const;
|
|
void SetConstraints(BList* constraints);
|
|
~Column();
|
|
|
|
protected:
|
|
Column(BALMLayout* ls);
|
|
|
|
protected:
|
|
BALMLayout* fLS;
|
|
XTab* fLeft;
|
|
XTab* fRight;
|
|
|
|
private:
|
|
Column* fPrevious;
|
|
Column* fNext;
|
|
Constraint* fPreviousGlue;
|
|
Constraint* fNextGlue;
|
|
BList* fConstraints;
|
|
|
|
public:
|
|
friend class BALMLayout;
|
|
|
|
};
|
|
|
|
} // namespace BALM
|
|
|
|
using BALM::Column;
|
|
|
|
#endif // COLUMN_H
|