Listbar — version history
The side navigation bar: collapsible accordion sections, entries with icons, the current entry marked with the accent color, and a collapse into an icon rail. Introduced in 1.0.
4.0 — October 2026 #
New #
is_badgeon an entry: a counter badge ("12"unread) at the end of the line, on the corner of the icon in the rail;""removes it.ue_item_rclicked(as_keys): the right-click on an entry, one event, without selecting it (nothing on a disabled entry) — to open your own menu.- Keyboard: Left / Right collapse and expand a section from its title (swapped in right-to-left), typing a letter goes to the entry that starts with it, section titles are reached with the arrows and folded with Enter or Space; the bar is a tab stop even with no selection.
- Rail mode (
ib_collapsed = true): every entry stays visible, a thin line separates the sections, an entry without an icon shows its initial, and the label is shown on hover. - The icon of a section (
is_imageofn_pbt_listbar_section) is displayed in front of its title. - Building a large bar under
of_set_redraw(false)draws it only once. [symbol=name]tag in rich text: eighteen monochrome glyphs that follow the text colour (clock,location,person,calendar,phone,mail,warning…); an unknown name stays as text.n_pbt_listbar_section.ib_pinned: pins a section at the bottom of the bar (Settings, Help); it stays in view while the bar scrolls, in the icon rail too, and the keyboard reaches it after the last entry above.
Fixed #
- The add methods refuse (
-5) a key already taken, a key containing/or|, and an entry under a section the bar has not added (it was displayed under the last section);of_remove_item,of_move_item,of_select_item,of_remove_sectionandof_move_sectionreturn-5for an unknown address. of_select_itemon a hidden entry returns-5; hiding the entry that is already selected keeps it selected.of_set_layoutreturns-5on a text that is not a layout (truncated file); the folded state of an absent section is no longer kept for a section added later.- Removing or clearing what holds the selection (
of_remove_item,of_remove_section,of_clear) raisesue_selection_changed(old, ""), andof_selected_keyreturns""afterof_clear. - Entry and section handles are freed by
of_remove_item,of_remove_sectionandof_clear. ue_layout_changedis raised when a section is folded (click orib_collapsed) and when an entry is removed, and no longer when entering the rail.of_reseton a bar in rail mode gives it back its width.- A color set on a section no longer colors an entry that has the same key.
- The keyboard is no longer lost after a label change, a selection, or when the focused entry is removed, hidden or folded away: the focus moves to its neighbor.
- A disabled entry takes the theme's "disabled" color, readable in light themes.
ib_auto_widthreports the width the longest label needs (it ended with "…"); it also applies to an expanded bar.- Dragging an entry (
ib_reorderable): releasing outside the window stops the gesture, and the end of a drag selects nothing. - A section with an empty title is separated from the previous one by a space (a thin line in the rail) and never folds.
- While a veto question is pending, going back to the current entry cancels the question without announcing anything; an entry removed during the question no longer becomes the selection.
- Tree accessibility roles (sections and entries), for screen readers.
- Rich text: a closing tag closes its own tag only (
[b]A[i]B[/b]CleavesCin italics only), a]escaped byof_escape_markupright after a tag no longer breaks the formatting around it, and[picture=…]accepts a data URI and a file name containing a comma. - Reading back
il_back_color_hoveroril_text_color_hoverof an item never coloured returns-1(the theme's colour), like the other item colours (it returned0, black). - Enter or Esc pressed in the component, when it does not use them, goes back to the window: the PowerBuilder
DefaultorCancelCommandButtonfires (the key was lost). - A disabled component (
ib_enabled = false) leaves the Tab order; enabled again (or afterof_reset), it takes its place back. - With no language chosen by the application, the component announces English to screen readers (it announced French).
is_theme_style,is_theme_modeandil_theme_accentread back the style and mode shown and the component's own accent (-1when it has none); an unknown or badly written value is ignored instead of leaving the component without a theme, and an axis left empty follows the application's theme.- The application accent (
PBT_SetDefaultThemeAccent) survives a change of theme, is followed as long as the component has no accent of its own, and repaints everything derived from it (hover, pressed, selections); Windows high contrast is supported.
Behavior changes #
ib_veto_selectionnow defaults tofalse:ue_selection_changingis only asked if you turn it on. Turned on, it is also asked forof_select_itemandof_clear_selection, which return-4if you refuse — see "Migrating from 3.0 to 4.0", sections 11.1 and 11.21.- A selection made by your code (
of_select_item,of_clear_selection) raisesue_selection_changedlike a click (it was silent), and setting a section'sib_collapsedraisesue_section_toggled. - A section without a title no longer folds: give it a title if it must fold.
of_countreturns alongandof_keys_attakes alongrank.- Rich text: a markup image on a network share (
[picture=\\server\share\x.png]) is no longer shown: go throughof_icon(), which embeds it.
3.0 — September 2026 #
New #
of_set_property,of_get_propertyandof_component_name: drive a property by its name (settings screen, saved configuration).
Fixed #
- The text of a hovered entry is readable in the Office 2007 theme, light and dark.
- A colour read back through a handle (
il_back_color,il_text_color…) returns the colour that was set, and-1for the theme's (it returned0, black). - Rich text: a
[word]that is not a tag is shown as typed (report[final].pdf) instead of disappearing with the rest of the text.
Behavior changes #
of_insert_section,of_move_section,of_insert_itemandof_move_itemcount the place from 1, likeue_item_reordered— see "Migrating from 2.0 to 3.0".
2.0 — September 2026 #
New #
- An entry is designated by its address, section then entry:
"nav/docs". Everything is done from the component:of_add_section,of_add_item("nav/docs", …),of_item("nav/docs"),of_select_item("nav/docs"); the add methods return a code. of_insert_section,of_move_section,of_remove_section(a section takes its entries with it).of_is_selected()on an entry;is_imageon a section;of_count,of_keys_at,of_hason the component and on a section.- The properties of an entry are read back live, tooltips included.
ue_script_error: a script error in the page reaches PowerBuilder with its message instead of being lost.
Fixed #
- Enter on a disabled entry no longer selects it.
is_imageof an entry reads back (it returned an empty string).
Behavior changes #
of_add_headerbecomesof_add_section,of_selected_sectionis gone (of_selected_keyreturns the full address), and the events take addresses:ue_selection_changed(as_from_keys, as_keys),ue_item_reordered(as_keys, ai_index),ue_section_toggled(as_key, …)— see "Migrating from 1.0 to 2.0".
1.0 — August 2026 #
New #
- Collapsible accordion sections (section
ib_collapsed,ue_section_toggled), entries with icons, label and icon changeable on the fly, disabled or hidden entries. - Collapse of the bar into an icon rail (
ib_collapsed); automatic width (ib_auto_width,ue_auto_width). - Selection (
of_select_item,of_clear_selection,ue_selection_changed) with a cancellable question before the change (ib_veto_selection,ue_selection_changing). - Entries rearranged with the mouse (
ib_reorderable,ue_item_reordered), layout saved and restored (of_get_layout,of_set_layout,ue_layout_changed).