23 #ifndef _LAX_BOXARRANGE_H
24 #define _LAX_BOXARRANGE_H
32 #include <lax/lists.h>
36 #define BOX_SHOULD_WRAP 100000
37 #define BOX_NO_BREAK 1000000
38 #define BOX_MUST_BREAK -1000000
52 #define BOX_FLOW_MASK (0x7)
54 #define BOX_HORIZONTAL (1<<3)
55 #define BOX_VERTICAL (1<<4)
56 #define BOX_WRAP_TO_X_EXTENT (1<<5)
57 #define BOX_WRAP_TO_Y_EXTENT (1<<6)
58 #define BOX_WRAP_TO_EXTENT (3<<5)
61 #define BOX_SET_Y_TOO (1<<7)
63 #define BOX_SET_X_TOO (1<<8)
64 #define BOX_SET_METRICS (1<<7|1<<8)
67 #define BOX_STRETCH_TO_FILL_X (1<<9)
68 #define BOX_STRETCH_TO_FILL_Y (1<<10)
69 #define BOX_STRETCH_MASK (1<<9|1<<10)
76 #define BOX_SPACE_TO_FILL_X (1<<11)
77 #define BOX_SPACE_TO_FILL_Y (1<<12)
78 #define BOX_SPACE_JUSTIFY (1<<13)
79 #define BOX_SPACE_MASK (1<<11|1<<12|1<<13)
85 #define BOX_ALIGN_MASK (63<<14)
86 #define BOX_HALIGN_SHIFT 14
87 #define BOX_HALIGN_MASK (7<<14)
88 #define BOX_LEFT (1<<14)
89 #define BOX_HCENTER (1<<15)
90 #define BOX_RIGHT (1<<16)
92 #define BOX_VALIGN_SHIFT 17
93 #define BOX_VALIGN_MASK (7<<17)
94 #define BOX_TOP (1<<17)
95 #define BOX_VCENTER (1<<18)
96 #define BOX_BOTTOM (1<<19)
97 #define BOX_CENTER (1<<15|1<<18)
99 #define BOX_STRETCH_IN_ROW (1<<20)
100 #define BOX_STRETCH_IN_COL (1<<21)
104 #define BOX_DONT_PROPAGATE_POS (1<<22)
107 #define BOX_HIDDEN (1<<23)
126 int nx,
int nw,
int npw,
int nws,
int nwg,
int nhalign,
int nhgap,
127 int ny,
int nh,
int nph,
int nhs,
int nhg,
int nvalign,
int nvgap);
130 virtual int hideBox(
int yeshide);
134 virtual void sync(
int xx,
int yy,
int ww,
int hh);
138 virtual int x() {
return m[0]; }
139 virtual int w() {
return m[1]; }
140 virtual int pw() {
return m[2]; }
141 virtual int ws() {
return m[3]; }
142 virtual int wg() {
return m[4]; }
143 virtual int halign() {
return m[5]; }
144 virtual int hgap() {
return m[6]; }
146 virtual int y() {
return m[7]; }
147 virtual int h() {
return m[8]; }
148 virtual int ph() {
return m[9]; }
149 virtual int hs() {
return m[10]; }
150 virtual int hg() {
return m[11]; }
151 virtual int valign() {
return m[12]; }
152 virtual int vgap() {
return m[13]; }
154 virtual int x(
int val) {
return m[0]=val; }
155 virtual int w(
int val) {
return m[1]=val; }
156 virtual int pw(
int val) {
return m[2]=val; }
157 virtual int ws(
int val) {
return m[3]=val; }
158 virtual int wg(
int val) {
return m[4]=val; }
159 virtual int halign(
int val) {
return m[5]=val; }
160 virtual int hgap(
int val) {
return m[6]=val; }
162 virtual int y(
int val) {
return m[7]=val; }
163 virtual int h(
int val) {
return m[8]=val; }
164 virtual int ph(
int val) {
return m[9]=val; }
165 virtual int hs(
int val) {
return m[10]=val; }
166 virtual int hg(
int val) {
return m[11]=val; }
167 virtual int valign(
int val) {
return m[12]=val; }
168 virtual int vgap(
int val) {
return m[13]=val; }
170 virtual int fpenalty() {
return fpen; }
171 virtual int fpenalty(
int val) {
return fpen=val; }
172 virtual int lpenalty() {
return lpen; }
173 virtual int lpenalty(
int val) {
return lpen=val; }
184 int nx,
int nw,
int npw,
int nws,
int nwg,
int nhalign,
int nhgap,
185 int ny,
int nh,
int nph,
int nhs,
int nhg,
int nvalign,
int nvgap);
189 virtual int Pop(
int which=-1);
190 virtual void Flush();
198 double *squishx=NULL,
double *squishy=NULL);
211 unsigned int elementflags;
214 int nx,
int nw,
int npw,
int nws,
int nwg,
int nhalign,
int nhgap,
215 int ny,
int nh,
int nph,
int nhs,
int nhg,
int nvalign,
int nvgap);
217 virtual int Pop(
int which=-1);
218 virtual void Flush();
232 int i,j,rowspan,colspan;
Mon Feb 17 2014 11:52:56, Laxkit