26 return QStringLiteral(
"CenterFocusedColumn");
42 return QStringLiteral(
"StripAxis");
49 return QStringLiteral(
"DefaultColumnWidth");
53 return QStringLiteral(
"DefaultColumnDisplay");
60 return QStringLiteral(
"DefaultColumnWidthKind");
64 return QStringLiteral(
"DefaultColumnWidthValue");
68 return QStringLiteral(
"DefaultColumnWidthPresetIndex");
74 return QStringLiteral(
"DefaultWindowHeight");
79 return QStringLiteral(
"DefaultWindowHeightKind");
83 return QStringLiteral(
"DefaultWindowHeightValue");
87 return QStringLiteral(
"DefaultWindowHeightPresetIndex");
94 return QStringLiteral(
"InsertPosition");
104 return QStringLiteral(
"AlwaysCenterSingleColumn");
108 return QStringLiteral(
"CenterShortColumns");
112 return QStringLiteral(
"RespectMinimumSize");
116 return QStringLiteral(
"CropStraddlers");
120 return QStringLiteral(
"FocusNewWindows");
124 return QStringLiteral(
"SmartGaps");
129 return QStringLiteral(
"StickyWindowHandling");
138 return QStringLiteral(
"TabIndicatorEnabled");
142 return QStringLiteral(
"TabIndicatorHideWhenSingleTab");
146 return QStringLiteral(
"TabIndicatorPlaceWithinColumn");
150 return QStringLiteral(
"TabIndicatorGap");
154 return QStringLiteral(
"TabIndicatorWidth");
158 return QStringLiteral(
"TabIndicatorLengthProportion");
162 return QStringLiteral(
"TabIndicatorPosition");
172 return QStringLiteral(
"PresetColumnWidths");
176 return QStringLiteral(
"PresetWindowHeights");
198 return QStringLiteral(
"TemplateColumns");
202 return QStringLiteral(
"width");
206 return QStringLiteral(
"display");
373 return qMax(0, qMax(1,
width) +
gap);
391 QRect content = columnRect;
394 content.setX(columnRect.x() + reserved);
397 content.setWidth(columnRect.width() - reserved);
400 content.setY(columnRect.y() + reserved);
403 content.setHeight(columnRect.height() - reserved);
410 return content.isValid() ? content : columnRect;
426 const int thickness = qMax(1,
width);
428 const int axisExtent = vertical ? columnRect.height() : columnRect.width();
433 if (axisExtent <= 0) {
438 const int length = qBound(1, qRound(axisExtent *
lengthProportion), axisExtent);
439 const int longOffset = (axisExtent - length) / 2;
460 return QRect(columnRect.x() - outward, columnRect.y() + longOffset, thickness, length);
462 return QRect(columnRect.x() + columnRect.width() - thickness + outward, columnRect.y() + longOffset,
465 return QRect(columnRect.x() + longOffset, columnRect.y() - outward, length, thickness);
472 return QRect(columnRect.x() + longOffset, columnRect.y() + columnRect.height() - thickness + outward, length,
664 if (presets.isEmpty()) {
668 for (
int i = 1; i < presets.size(); ++i) {
669 if (qAbs(presets.at(i) - fraction) < qAbs(presets.at(best) - fraction)) {
680 return presets.isEmpty() ? fallback : presets.at(
nearestPresetIndex(presets, fraction));
693 return qMax(1, qRound(proportion * (workExtent + gap)) - gap);
728template<
typename Resolver>
734 const bool forward = delta >= 0;
739 for (
int i = 0; i < count; ++i) {
740 const int px = resolve(i);
742 if (currentPx + 1 < px && (best < 0 || px < bestPx)) {
746 if (wrap < 0 || px < wrapPx) {
751 if (px + 1 < currentPx && (best < 0 || px > bestPx)) {
755 if (wrap < 0 || px > wrapPx) {
761 return best >= 0 ? best : wrap;
900 return tiles.isEmpty();
913 return tile.minimized ? nullptr : &tile;
945 return !
tiles.isEmpty();
949 for (
int i = 0; i <
tiles.size(); ++i) {
950 if (
tiles.at(i).windowId == windowId) {
963 for (
int i = tileIdx - 1; i >= 0 && anchor.isEmpty(); --i) {
964 anchor =
tiles.at(i).windowId;
966 for (
int i = tileIdx + 1; i <
tiles.size() && anchor.isEmpty(); ++i) {
967 anchor =
tiles.at(i).windowId;
1170 QVector<const ResolvedColumn*> visible;
1172 if (column.
rect.intersects(workArea)) {
1173 visible.append(&column);