PBToolboxAI AcheterBuyKaufenAcquistaComprarComprar

← Historique de tous les composants← History of every component← Versionsverlauf aller Komponenten← Cronologia di tutti i componenti← Historial de todos los componentes← Histórico de todos os componentes

L'historique des versions est publié en anglais.Version history is published in English.Der Versionsverlauf wird auf Englisch veröffentlicht.La cronologia delle versioni è pubblicata in inglese.El historial de versiones se publica en inglés.O histórico de versões é publicado em inglês.

Context menu — version history

u_pbt_contextmenu · Introduced in 5.0

The Windows context menu in the theme of the application: a cascading list opened at the cursor, under a control or at a point of the screen. Introduced in 5.0.

5.0 #

New #

  • An invisible launcher: drop it anywhere with no size, it only exists while its menu is open.
  • Entries named by their address, as deep as needed: "copy" at the top, "export/pdf" in the cascade of an export entry (of_add_item, short form or with an icon and a check mark). ue_item_selected(as_keys) hands back that same address, so two cascades may name their entries alike.
  • of_add_item refuses (-5) a parent that does not exist, an address already taken, an empty level (export/, /pdf) and a key containing | or starting with __.
  • Three ways to open: at the cursor (of_show(), from the right-click of the control the user clicked), under a control (of_show_under: below its bottom edge, aligned on its start edge, above it when the screen ends below — for a More or … button), or at a point of the screen (of_show(x, y), negative coordinates included).
  • One answer per opening: a choice (ue_item_selected) or none (ue_dismissed — a click outside, Escape, of_close, or a menu with nothing to show). An entry disabled, hidden or removed while the menu is open can no longer be chosen; of_remove_item, of_clear and of_reset close an open menu. of_is_open tells whether a menu is on screen.
  • Separators (of_add_separator) and section headers (of_add_header) at the top of the menu or in a cascade, never chosen nor counted; a separator is never shown leading, trailing or doubled, and a header whose entries are all hidden goes with them.
  • Through the handle of an entry (of_item(address), a bare key resolved to the one entry that carries it): label (is_text), disabled (ib_enabled), hidden (ib_visible, cascade included), check mark (ib_checked), icon changed in place (is_image), radio group (is_group: the entries of one group under the same parent are exclusive, with a round bullet), shortcut shown at the right (is_shortcut, shown only: the key belongs to the control the menu is about), and the five colours of an item.
  • of_remove_item removes one entry and its cascade; of_clear and of_reset empty the menu; the handles of what leaves are released.
  • ib_track_hover and ue_item_hover(as_keys) tell which entry the pointer or the keyboard is on — a disabled one too — and an empty address when the menu closes: the help line of a status bar.
  • Keyboard: arrows that skip disabled entries, Right to open a cascade, Left to close it, Enter to choose, Escape to go back one level then close; the letter after & in a label chooses the entry, and typing the first letters of a label goes to it. Long lists scroll and stay fluid.
  • Right-to-left applications are followed: the menu aligns on the right and the cascades open to the left.