Repository navigation
System notifications, bringing windows forward with badges and attention requests, rich text paragraphs, scroll areas that stay at their end, integrated title bars on macOS, custom areas that take focus and text, macOS text at the width the system draws it, and keys and assistive technology requests handled in the order they arrive.
Added
- The new
cpui-notifycrate shows system notifications on macOS, iOS, Windows and Linux, replaces or removes them by key, and reports which one the user clicked. (#78) Ui::focus_windowbrings a window to the front,Ui::request_attentionasks for the user's attention with a bouncing Dock icon or a flashing taskbar button, andUi::set_badgeshows a count on the application's icon. (#77)Ui::rich_textlays out one paragraph of bold, italic, inline code, colored text, links and tags that wraps, selects and copies as one text, with links and tags reachable by keyboard and screen readers and reporting the key they were given when clicked. (#76).stick_to_end()keeps a scroll area or list at its end while it is there, so new lines stay in view as in a chat or a log, andUi::is_scrolled_to_endandUi::scroll_to_endread and set that. (#75)Options::integrated_title_barextends the content of a macOS window into its title bar,Ui::title_bar_insetskeeps controls clear of the window buttons, anddrag_windowon a container moves the window by its empty space. (#71)Ui::custom_areadeclares an area drawn inApp::paintthat can take keyboard focus, keys and input method text, andUi::set_ime_caretopens the candidate window at its caret. (#70)Ui::font_systemmeasures text and places carets during layout with the fonts the window draws with,Ui::scale_factorgives the display scale before drawing, andcpuiexportsFontSystem,TextDirectionandTextCluster. (#67)clicks()on a widget or itsResponsereturns how many clicks in a row this frame's click completes, so custom widgets can tell single, double and triple clicks apart. (#66)Ui::animate_withgives a transition its own duration and curve, set withMotionandEasing, including cubic Bézier curves. (#57)Ui::clipboard_textreads text from the clipboard. (#56)Options::max_sizelimits how large the user can make a window, andOptions::always_on_topwithUi::set_always_on_topkeeps a window above others. (#55)Ui::scroll_to_rowscrolls a list to a row, even one far from the view, andUi::scroll_into_viewscrolls a widget into view without focusing it. (#54)Input::push_keyadds an editing key after the text typed so far, so frames driven by hand keep the order of keys and text. (#53)
Changed
- Setting the same window title again, as a frame may, no longer allocates or sets it on the window again. (#77)
- Comboboxes search large option lists faster for queries containing Han characters. (#60)
- Opening large combobox lists is faster when the search field is empty. (#59)
- Searching large combobox lists is faster when labels start with ASCII text. (#58)
- Closed, unfocused comboboxes take less time to redraw. (#50)
Deprecated
Ui::customandCustomOptionsare deprecated in favor ofUi::custom_area, whoseopaqueandrevisiontake the same settings, and will be removed in 0.2.0 at the earliest. (#84)
Fixed
- Text in variable fonts with an optical-size axis, such as the macOS system font, now uses the design the font has for its size, so small text is no longer about 10% narrower than in other apps. (#83)
- A disabled widget whose only accessible description comes from its
aria_*settings is reported to assistive technology as disabled. (#70) - Several requests from assistive technology before the same frame each apply to their own control, in the order they arrived, instead of one replacing another or stepping the wrong slider. (#61)
- Keys and text that arrive before the same frame take effect in the order they were typed, so Backspace no longer removes a later character, text typed after Tab goes to the next field, and text typed after Enter follows what Enter did. (#53)
- Pressing an arrow key right after Home or End on tabs no longer lands on the wrong tab. (#52)