Changeset View
Changeset View
Standalone View
Standalone View
src/kexiutils/FlowLayout.cpp
Show First 20 Lines • Show All 256 Lines • ▼ Show 20 Line(s) | 249 | { | |||
---|---|---|---|---|---|
257 | QSize minSize, sizeHint(20, 20); | 257 | QSize minSize, sizeHint(20, 20); | ||
258 | int minSizeHeight = 0 - spacing(); | 258 | int minSizeHeight = 0 - spacing(); | ||
259 | 259 | | |||
260 | while (it.hasNext()) { | 260 | while (it.hasNext()) { | ||
261 | QLayoutItem *o = it.next(); | 261 | QLayoutItem *o = it.next(); | ||
262 | if (o->isEmpty()) // do not consider hidden widgets | 262 | if (o->isEmpty()) // do not consider hidden widgets | ||
263 | continue; | 263 | continue; | ||
264 | 264 | | |||
265 | // qDebug() << o->widget()->className() << " " << o->widget()->name(); | 265 | // qDebug() << o->widget()->className() << o->widget()->name(); | ||
266 | QSize oSizeHint = o->sizeHint(); // we cache these ones because it can take | 266 | QSize oSizeHint = o->sizeHint(); // we cache these ones because it can take | ||
267 | // a while to get it (eg for child layouts) | 267 | // a while to get it (eg for child layouts) | ||
268 | if ((x + oSizeHint.width()) > r.right() && h > 0) { | 268 | if ((x + oSizeHint.width()) > r.right() && h > 0) { | ||
269 | // do the layout of current line | 269 | // do the layout of current line | ||
270 | int sizeHintWidth, minSizeWidth, lineMinHeight; | 270 | int sizeHintWidth, minSizeWidth, lineMinHeight; | ||
271 | doHorizontalLayoutForLine(r, currentLine, | 271 | doHorizontalLayoutForLine(r, currentLine, | ||
272 | spacing(), d->justify, y, h, availableSpace, expandingWidgets, | 272 | spacing(), d->justify, y, h, availableSpace, expandingWidgets, | ||
273 | sizeHintWidth, minSizeWidth, lineMinHeight, testOnly); | 273 | sizeHintWidth, minSizeWidth, lineMinHeight, testOnly); | ||
▲ Show 20 Lines • Show All 181 Lines • Show Last 20 Lines |