Chepatapa Apps
← Build Log

Nov 2026 · Flare / build notes

Fitting Flare on the iPhone Duo

The iPhone Duo folds. Its outer display is 466 by 678 points, the inner one 669 by 951, and either can be used in portrait or landscape. Flare 1.5.0 is the first version built for it. Most of the work was small layout fixes. One bug was not small: folding the phone emptied the log.

Treat it as a window, not a device

The tempting approach is to detect the Duo and branch on it. The better one is to forget the device and treat the app as a window that can be any size and change size while you use it. A layout that handles that also works in iPad Split View and Stage Manager, and on whatever device comes next.

The iOS side was already fine: no full-screen lock, a scene-based lifecycle, no orientation locks, and nothing in the Dart code that read the screen size directly. The rest was the Flutter layout.

A test matrix before the simulator

The first pass was a static audit against a list of known anti-patterns: fixed heights in sheets, hard-coded width caps, if (wide) Row else Column, height thresholds, and safe areas that assume left and right are the same. Then came a layout test that renders 13 screens in the four Duo window sizes, in English, German and Russian (the longest strings), at text scales from 1.0 to 2.0, with a safe-area inset on one side only. Any text that gets cut off or any overflow fails the test.

Screens × windows

13 × 4

Languages × text scales

3 × 1.0–2.0

What the sweep found

One-sided safe areas. On the outer display in landscape, the system bar sits on one side only. The tab bar now keeps the tabs clear of it, and the tablet width cap no longer adds that inset twice.

Width caps. Forms are capped at about 480 points and reading content at about 672, with full-width backgrounds behind them. On the inner display Flare's own dialogs had stretched to about 790 points; they now stop at 400.

Short windows. The outer display in landscape is only 466 points tall. The reminder time sheet was cut to 9/16 of that. Edit Entry pinned Save and Delete and left about 120 points for the form, so Delete now scrolls with the form on a short window. At the largest text size, the pinned tab headers filled the whole window, and Insights showed no content at all. On short windows their text scale is now capped at 1.5.

The bug that emptied the log

The last check was on the Duo simulator, folding and unfolding with entries loaded. After a fold, the log was empty, and it stayed empty until a restart.

The cause was the width cap itself. Below 600 points it returned the content as is; above 600 it wrapped the content in a layout builder with centering padding. To Flutter those are two different widget trees, so crossing 600 points threw away every tab and built it again. The old log screen's dispose step dispatched EntriesReset, and it ran after the new screen had already loaded the entries.

The fix was to make the cap always build the same tree and only change its padding. On a phone that never changes size, this bug can't happen, which is exactly why the layout tests didn't catch it and the simulator did.

Large text, while I was there

The same release fixed the leftovers at large text sizes: tab labels grow with the system text size, wrapped button labels stay centered, and the paywall comparison table and the Describe it field no longer clip. Kin Compass got the same treatment a couple of weeks earlier, with layout tests for every main screen at large text.

Where it stands

Flare 1.5.0 is live on iOS and Android. Everything above was checked in tests and on the Duo simulator: both displays, both orientations, folding with a sheet open and mid-edit, and the largest text size. It hasn't been checked on real hardware yet, so the real fold and the side system bar stay on the list.

The takeaway

A layout switch that changes the widget tree also throws away state, and you only see it when the window actually changes size. Switch padding and constraints, not tree structure, and test live resizing as well as fixed sizes. The fixed sizes cover most of the layout bugs, but the one that lost the user's data only showed up during a resize.