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.

XML tree — version history

u_pbt_xmltree · Introduced in 3.0

An XML document displayed like a foldable code editor — line numbers, coloured tags, attributes and text, search — whose every line reports its XPath. Introduced in 3.0.

4.0 — October 2026 #

New #

  • Every attribute is a target: a click gives its path (/order/@id), of_select_path selects it, of_selected_value returns its value; Right arrow on a tag walks through its attributes one by one (Left arrow comes back).
  • of_selected_xml, of_copy and Ctrl+C: the XML of the selection.
  • of_expand_path, of_collapse_path and of_is_expanded open, fold and query one element by any XPath; the new ue_node_toggled(as_path, ab_expanded) event reports a fold or unfold by the user or by these two methods.
  • of_select_path accepts any XPath (//line[@sku='A'], /r/a[1]): the first matching node is selected, and of_selected_path then returns the tree's own path.
  • An invalid XML shows its source around the faulty line, numbered, with the line marked and the column underlined (an error past the end of a line marks the line end).
  • Large documents only draw the lines on screen: 8,000 sibling elements appear in a fraction of a second, and arrow keys answer in milliseconds.
  • F3 and Shift+F3 go to the next / previous search match; screen readers get the tree structure and the selected line.
  • Search options, like the code editor: ib_find_match_case finds only the text with the same case, ib_find_whole_word finds it only as a whole word (id is no longer found inside user_id); the search box (Ctrl+F) has the matching Aa and ab toggles, and a change of option runs the search again. Both are off by default: the search stays as it was.

Fixed #

  • CDATA content is shown (the element used to look empty); comments, processing instructions and the XML declaration are displayed; mixed content keeps its text in document order and significant spaces; each line stays valid XML (", 
, &, <, ]]>).
  • A <?xml-stylesheet?> without XML declaration is shown once, no longer twice.
  • is_xml reads back exactly as it was set, invalid text included; is_xml = "" empties the tree without an error; of_clear empties the tree and keeps ib_wrap and ib_search_enabled (of_reset restores everything).
  • A document with a real <parsererror> element is displayed like any other.
  • Search counts occurrences, each one highlighted, with a single current one; it only opens the elements that hide the current match, and of_clear_search restores the folds from before the search; a new document refreshes an open search bar.
  • A search no longer folds or moves the selected line; folding the element that holds the selection moves the selection onto it and says so in ue_selection_changed; ue_selection_changed is no longer raised when nothing changes.
  • Keyboard: no more blocking on an element with both text and children, closing tags are skipped, Right arrow on a leaf does nothing, and multi-line text, CDATA or comments are followed by search and Page Up / Page Down.
  • Focus given to the component (Tab, of_focus_webview) goes to the tree, so arrows and Enter work; Enter on a leaf raises ue_node_clicked instead of pressing the window's default button; Escape first closes the search bar.
  • ue_error is written in the display language, including when the language changes just before the document is set.
  • Reading back a long text value takes time proportional to its size and returns it whole (it slowed down with the size and was cut beyond a million characters).
  • Enter or Esc pressed in the component, when it does not use them, goes back to the window: the PowerBuilder Default or Cancel CommandButton fires (the key was lost).
  • With no language chosen by the application, the component announces English to screen readers (it announced French).
  • is_theme_style, is_theme_mode and il_theme_accent read back the style and mode shown and the component's own accent (-1 when 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 #

See the 3.0 → 4.0 migration guide, sections 11.3, 11.6, 11.29 and 11.30.

  • The path of an element under a default namespace (xmlns="urn:…") is /*[local-name()='Envelope']/*[local-name()='Body'], an XPath that n_pbt_xml.of_get_value reads as is (it used to be /Envelope/Body, which matched nothing). A prefix redeclared with another URI, or a same-name sibling in another namespace, also gets a path that designates exactly that node.
  • A text, comment or processing-instruction line has its own path (/r/text()[2], /r/comment()[1]), no longer its element's.
  • of_select_path with an unknown path returns -5 and the selection does not move; it opens the elements that hide the target, and raises ue_selection_changed like the keyboard does.
  • ue_error reads "Invalid XML: line 1, column 11 (…)" in the display language: do not parse its text.
  • A document of more than 1,500,000 lines is refused with a message and ue_error.
  • The tree is always laid out left to right (an XML document is left-to-right text); only its search bar follows a right-to-left application.

3.0 — September 2026 #

New #

  • First release: an XML value set in is_xml shown as a foldable, coloured code view — line numbers, a fold marker on each element, optional line wrapping (ib_wrap).
  • Search with highlighting and navigation (of_search, of_search_next, of_search_prev, of_match_count, ue_search_result), a built-in search bar (ib_search_enabled).
  • of_expand_all, of_collapse_all, of_expand_to_level; of_select_path, of_selected_path, of_selected_value.
  • ue_node_clicked reports the path of the clicked node, ue_selection_changed a keyboard move, ue_error an invalid XML.
  • ue_script_error: a script error in the page reaches PowerBuilder with its message instead of being lost.
  • of_set_property, of_get_property and of_component_name: drive a property by its name (settings screen, saved configuration).