Repository navigation
v0.17.0
Added
Core
-
Rebindable edit shortcuts. Every widget tree registers
edit.undo,
edit.redo,edit.cut,edit.copy,edit.paste,edit.paste_plainand
edit.select_all(StandardEdit) on their usual chords, in anedit
category.ShortcutSettingslists them under Edit, named in the
application's language, so a user can rebind them or give them a second
chord.StandardEditis in the prelude. -
BuildContext::register_shortcut_sharedand
ShortcutRegistry::register_sharedregister a global shortcut that several
widgets declare together. It stays registered while any of them lives. -
clear_focus.EventContext::clear_focusand
WidgetTree::clear_focusdrop the keyboard focus, so nothing is focused.
A click on space that takes no focus still keeps it, as in Qt and AppKit;
on_tap(|_, ctx| ctx.clear_focus())on a background gives the browser
behaviour. -
AccessibilityInfo, fromWidgetTree::accessibility_node, carries a
node's value, numeric value and range, and custom-action labels, after the
application'saccess_*overrides. -
OverlayPlacement::BelowSelection, the mirror ofAboveSelection: below
a rectangle, flipping above when there is no room. -
AsyncCompletionHandle::drain_intoruns the completions of
spawn_local_withagainst a headless tree, each with anEventContext, so
a handler that shows a toast or a modal after anawaitcan be tested.
spawn_local_withno longer panics in a context without a window. -
WidgetTree::try_accessibility_nodeanswersNonefor a destroyed
widget, andAccessibilityInfo::publishedsays whether assistive
technology can reach the node: a dormant page, an excluded or merged
subtree and a hidden node are not published. -
BuildContext::attached_tap_buttonsreads the buttons anon_tap
attached to a node from outside answers to. -
WidgetTree::declared_cursor(id)reads the cursor a widget declares, and
tells a declaredDefaultfrom none, so a test can check a.cursor(..)
without hovering it.current_cursoris documented: the cursor shown now,
which changes as the pointer enters or leaves a node.
Widgets
-
Rebindable editor shortcuts.
RichTextEditordeclaresformat.bold,
format.italic,format.underlineandformat.insert_paragraph
(FormatShortcut), andCodeEditordeclarescode.toggle_commentand
code.duplicate(CodeShortcut), on their usual chords. They are listed in
ShortcutSettingsunder Format and Code while an editable editor exists. A
read-only viewer declares none. Toggle comment also answersCtrl+Shift+/,
for the layouts that type/with Shift. -
localize_standard_shortcutsnames the standard edit shortcuts of a
registry in the active language.teksilo-appcalls it for every window. -
ShortcutSettingshas a toolbar: a search field, "Find by keys" (press a
chord to list the commands that use it), "Modified only" and "Reset all…".
ShortcutSettings::toolbar(false)hides it;modified_only(signal)binds
the "Modified only" state. -
keystroke_partsreturns the label of each key of a chord, one per key cap. -
BuiltInIconshasresetandkeyboardicons. -
GridView::detail_row_whensays which tiles have a detail band, from
the sameTileContextdetail_rowreceives. A tile it refuses is no longer
offered to a screen reader as expandable, and activating it opens nothing.
Without it, every tile is still offered as one. -
TextInputappearance.TextInputandTextInputFieldtake a
text_style(a typography role that follows the theme, or a fixed style),
shaped at its size and in its family, with the placeholder matching and the
field's height following the line; atext_alignmentthat places a text
narrower than the field at its start, centre or end, the caret, clicks,
selection and IME window following; and atext_colorfrom a colour, a
role or a signal, for instance one colour at rest and another while
focused.TextInput::min_heightreplaces the field's minimum height, under
the default, Fluent and macOS styles alike. -
Slider::jump_on_pressmoves the value when a mouse button goes down
on the slider, not when a drag starts or the button is released; touch and
pen are unchanged.value_tooltip_placementputs the value readout above
or below the thumb, or at the pointer while dragging
(SliderValueTooltipPlacement), andvalue_tooltip_stylegives it a
tooltip style of its own. -
GridView::min_columnsandmax_columnsbound the column count of
fixed-width and adaptive tiles; a minimum the width cannot afford narrows
the tiles rather than overflowing.column_alignmentplaces a block of
columns narrower than the viewport at the leading edge, the centre or the
trailing edge. -
ScrollAreascrolls sideways on Shift+wheel when it can scroll
horizontally, likeTabBarand the table views;
shift_wheel_scrolls_horizontally(false)turns it off.
reveal_bars_on_hover(true)shows overlay scroll bars while the pointer is
over the area. -
SplitterModel::set_pane_visible_immediatehides or shows a pane without
sliding it. -
MenuList::insetsets the gap between a menu's surface and its rows
(4 dp by default), andMenuList::surface_stylegives one menu its own
popover style, ahead of the theme's, without touching combo-box dropdowns. -
A
ButtonStylecan pick the label colour per interaction state with
label_text_role_for, for example to brighten it on hover. Existing
styles and the presets are unchanged. -
MessageBox::title_alignmentandbutton_alignmentplace the title and
the buttons, for instance centred as in a macOS alert. -
CheckboxandRadioButtontakelabel_style,label_color,
caption_styleandcaption_color. -
Scroll handles on the data views.
handle()onListView,
TreeView,TableView,TreeTableViewandGridViewreturns a
cloneable handle that scrolls the mounted view to an item
(scroll_to_index/ensure_index_visible,scroll_to_row/
ensure_row_visible, andGridViewHandle::reveal_band). It can be taken
before mount, survives rebuilds, and is applied at the next layout, so it
lands on the right item after a same-turn insert, expand or opened detail
band, also with auto-measured row heights. -
GridView::detail_visible_span_signalreports which part of the open
detail band is on screen, so a band holding hundreds of rows can build
only the rows in view. -
PopoverWidget::on_close_withtells the callback why the popover closed
(DismissReason). -
The keyboard cursor of a data view.
GridViewHandle,ListViewHandle
andTreeViewHandlegaincursor(),set_cursor(..)and a read-only
cursor_signal(). In a multiple selection the cursor moves apart from the
selection; setting it moves the focus ring and the announced item without
moving keyboard focus, the selection or the scroll position.
cargo-teksilo
-
symbollists a struct's public fields, with their types and docs,
and says when the struct also has fields that are not public. The theme
token structs (ColorTokens,TypographyTokens,TextStyle, …), whose
whole API is their fields, can now be read from the tool.-f jsongains
fieldsandrestricted_fieldson each struct. -
symbolshows what each enum variant carries:KeyDown { key: Key, modifiers: Modifiers, text: Option<String> },Fraction (f32). The JSON
variants gain the sameshape. -
symbolfinds methods and free functions. A name that is not a type
answers with its owner instead of "unknown type":symbol subscribe_frame_tickshows the method onBuildContextand says to look
upBuildContextfor the rest;symbol spawn_blockingshows the free
function in teksilo-async. A trait's method comes first (on_tapis
WidgetBuilder's).Type::methodnarrows to one owner, and a name with
many owners (new) lists theType::nameforms to pick from. -
symbolfinds macros: the procedural macros (res!,tr!,
teksu!,#[derive(IntentKind)]) with their crate's usage doc, and every
#[macro_export]macro (compile_in_locales!,lit!) with the forms it
accepts. They answered "unknown type" before. -
symbolsays where to import each item from: an Import: line
under every type, function, constant and macro gives the shortestuse
path throughteksilo(teksilo::core::ObserverHandle,
teksilo::prelude::Theme), the umbrella feature it needs when a default
build lacks it (WebView:web-view-headlessorweb-view), the crate to
add whenteksilodoes not re-export it (teksilo_scene::SceneView), or
that nothing outside its crate can reach it.-f jsongainsimports,
every path, best first. rustc suggests none of these paths. -
symbolprints methods under the doc of theimplblock they are
written in:WidgetTree's test API now reads as "Simulated input" and
"Test inspection", each introduced by what it is for. -
statusreports theteksilo-automation-mcponPATH, and whether
its version matches the app's teksilo; when it does not, it prints the
cargo install teksilo-automation-mcp --version <x>line.--jsongains
automation_server. -
symbolprints a setter's default when the type's constructor sets
the field to a literal:HStack::spacingdefaults to0.0. -
symbolresolves an enum variant to its enum:symbol FixedColumnCountshowsGridSizing.
Automation
inspect_nodeandlayout_treereport each widget's declaredcursor,
andquery_pointersgives the hovering pointer the cursor the window
shows.
Documentation
- The generated catalog pages list the same fields and variant payloads,
and each item's import path. - The layout guide and the skill say that a widget added as a tree's root
is laid out at the whole viewport, and how to test one at its own size.
Changed
Core
-
Behaviour change: a shortcut whose intent no
Actionhandles no longer
consumes its key: the focused widget receives it as a plainKeyDown. An
intent every action passed on withPropagatedcounts as not handled. -
Behaviour change: an application shortcut on
Ctrl+Z,Ctrl+Y,
Ctrl+X,Ctrl+C,Ctrl+V,Ctrl+A,Ctrl+Shift+ZorCtrl+Shift+V
now shares its chord with a standard edit shortcut. Handle theedit.*
intent with anActioninstead. The same holds forCtrl+B,Ctrl+I,
Ctrl+UandCtrl+Enterwhile aRichTextEditorexists, andCtrl+/and
Ctrl+Dwhile aCodeEditordoes. -
Behaviour change: under a touch or a pen, a widget with no width or
height no longer catches a press that misses near it. -
Breaking.
OverlayPlacementhas a new variant, so an exhaustive
matchon it needs aBelowSelectionarm.TextInputStyleConfighas a
newmin_heightfield. -
The
Debugtext of a mounted widget built with handler methods says the
handlers moved to the tree, instead of showing an empty set with
cursor: None.
Widgets
- Behaviour change: undo, redo, the clipboard and select-all in
TextInputand the fields built on it,RichTextEditor,CodeEditorand
LogView, and select-all inListView,TreeView,TableView,
TreeTableViewandGridView, follow theedit.*bindings instead of
fixed chords. A command a widget declines (Cut or Paste in a read-only
field, a command its filter refuses) reaches an application'sActionfor
the same intent. - Behaviour change: bold, italic, underline and the forced paragraph
insert inRichTextEditor, and comment and duplicate inCodeEditor,
follow theformat.*andcode.*bindings instead of fixed chords. - The context menus of those editors show the bound chord.
- A
TableVieworTreeTableViewwithout a multi selection mode no longer
takesCtrl+A. CommandPalettedoes not list the standard edit commands, nor the
format.*andcode.*ones.- Behaviour change:
ShortcutSettingsis redesigned. Chords are drawn as
key caps and are the controls: clicking one, or Enter on it, records a new
chord in place, and the+beside it adds an alternative. The Rebind,
Rebind 2nd and Reset buttons are gone; a changed row is marked with a dot
and gets its own reset button. - Behaviour change:
ShortcutSettingsasks before it takes a chord from
another command (confirm_conflictsis on by default). ShortcutSettingsrefuses a chord without Ctrl, Alt or ⌘ (except function
keys), and the chords the system or the framework keeps (Ctrl+Tab, Alt+F4,
Alt+Tab, ⌘Tab, ⌘Space and others), and says why.ShortcutSettingsis one Tab stop; the arrow keys, Home and End move
between its rows and columns. Each control's accessible name says the
command and its chord, and the group titles are headings.ShortcutSettingssorts commands by name and groups by title, in the
interface language, translates all its text, and searches the text of the
chords instead of the internal ids. A shortcut that is currently disabled
can still be rebound.- Behaviour change: Shift+wheel scrolls a
ScrollAreathat can scroll
sideways horizontally (see Added). - Behaviour change: in a right-to-left layout, a
GridViewof
fixed-width tiles that leaves width over now puts its columns at the right
edge, its leading edge. child_optonVStack,HStack,ZStack,Grid,ColumnFlow,
MasonryLayoutandWraptakes a widget id, aschilddoes.GridView::ensure_index_visibleleaves a tile that is already fully
visible alone, whatever the anchor.
Fixed
Core
-
A focus request into a control that the same handler reveals was
lost. Showing aSwitcherpage or avisible_whenbranch and asking for
focus on a control in it moved the focus, at the next layout, to the page's
first control, or dropped it. The request now waits for that layout and
focuses the control it named. -
accept_tap_buttonsretargeted a widget's own click. Widening an
application'son_tapon aSliderto the secondary button made a right
click jump the value and a left click do nothing. A tap mask (and the
double-tap, triple-tap and long-press masks) now applies to the handlers
set beside it; a widget's own keep their buttons. -
A popover that opens on a right click closed and reopened on a second
right click on its trigger. A press on the trigger now toggles it whenever
the trigger accepts that button.
Widgets
-
set_column_pinning(id, PinnedSide::None)could not unpin a column
declared pinned on aTableViewor aTreeTableView: it put the column
back on its declared side. It now unpins it, as dragging the column out of
its pane does. Giving the column's declared side removes its override. -
Removing a row from a large keyed selection in a
ListViewor a
TableViewcost the row count times the selection. The selection now
drops the removed keys after reading each of the view's keys once, as a
GridView's does. -
An
OverlayTriggeraround a composite control did not open on a pointer
click when the control's focus stop handled taps itself: only Enter,
Space and a screen reader's click opened it. It now opens on the click,
with the button mask the application set. -
ComboBoxannounced a value its trigger did not show when the bound
selection was not among the items. It now announces the placeholder it
shows. -
A cursor-only move in a
ListVieworTreeViewwas not announced.
With a multiple selection, Ctrl+arrows moved the cursor but a screen
reader kept hearing the old row as current.
cargo-teksilo
-
symboldropped the enum variant after each plain//comment inside
an enum: the comment and the variant were read as one unnamed variant.
KeylostA,F1andCapsLockthis way, andAutomationOp,
CodeCommandandEditCommandKindlost variants too. A comment after the
last variant showed as an unnamed variant (AnimatedQuadKind). -
statusreported an older release's Claude skill as missing once
every one of its files differed from this release's, which is the usual
case two releases on. It now lists the copy as differing and prints the
agent install claude --forceline, at project and at user scope. -
symbol Widgetdescribed the code editor'swidget.rs, andsymbol Paintthe rich text editor'spaint.rs: a module of the same name in the
searched crate hid the type the umbrella re-exports. Both, andPath,
Rect,ThemeandColorunder--crate, now resolve to that type. -
symboland the catalog pages left out the methods a type defines in
other files.WidgetTreeshowed 134 of its 322: none of the test API
(click,tap_with,touch_down,advance_time,tab_stops_within)
or ofdispatch_pointer.TreeViewshowed 1 of 37,SceneView2 of 93
andOverlayManager48 of 49. A type now lists every inherent method its
crate writes for it.
Documentation
- The icons guide said no image texture is ever freed, and advised
ImageWidget::new(&icon)for runtime images such as album covers. Since
0.16.0 anImageWidget::from_rawtexture goes with the first frame that
does not draw the widget. The guide now separates the shared textures a
window keeps (res!(),ImageWidget::new,IconWidget::from_raster)
from the ones that follow what is on screen, and recommendsfrom_raw
for images that come and go. - The documented change order of
ListModel::reconcile_by_keyis what it
emits: the removals, then one pass in target order in which moves, updates
and inserts interleave, each index valid after the previous change. - About thirty doc comments that an old edit had duplicated, or spliced into
the neighbouring item (RadioButton::on_change,MenuItem::for_shortcut,
TreeView::scroll_bar_styleand others), document their own item again. - The
Below,AboveandBelowPreferredplacements say that they widen
an overlay to at least its anchor's width, and the overlay guide shows how
to open a popover on a right click. Shrinkable,LayoutResponse::shrinkand the layout guide say that a
child at its floor hands the rest of its share on, so a much larger weight
shrinks one child fully before another starts.- The scroll-to methods of the data views' builders say that they act at
call time against the last layout;ListView::scroll_to_indexclaimed a
call before the first layout was applied later. - The testing notes say how to read what a screen reader is told
(announcements_sinceafter onesync_accessibility), how to deliver
subscribe_eventcallbacks in a headless tree (a poster that records,
replayed throughdispatch_subscription_event), and that a press and a
release sent throughdispatch_pointerform a tap, asclickand
tap_withdo in one call. WidgetTree's documentation sets apart its simulated input (taps, keys,
touch, pen, gestures and the simulated clock, for headless tests and the
automation bridge) and its test inspection methods from the rest, under a
heading each on docs.rs.sync_accessibilitysays that it returns the whole tree on every call,
that adapters receivedeliver_accessibility's update, and that
at_versiontells a test that something changed.
Full Changelog: v0.16.0...v0.17.0