All Manuals > Release Notes and Installation Guide > 12 Release Notes

12.5 New CAPI features

See the CAPI User Guide and Reference Manual for more details of these, unless directed otherwise. This section is not relevant to LispWorks for Mobile Runtime.

12.5.1 New thread-safe function to force a redisplay part of an capi:output-pane

The new function capi:redisplay-element can be used to force part of an capi:output-pane to be redisplayed. It's first argument can be an capi:output-pane or a capi:pinboard-object and it is equivalent to calling gp:invalidate-rectangle, except that it can be called from any thread.

12.5.2 Row and column separators in list panels

The classes capi:list-panel and capi:multi-column-list-panel now support visible separators between rows or columns by the new :separators initarg, with value nil (the default), :both, t, :horizontal or :vertical.

12.5.3 Support for reorderable columns in capi:multi-column-list-panel on GTK

The class capi:multi-column-list-panel supports reorderable columns on GTK by the new initarg :reorderable-columns and the :reorderable keyword in the column specification. Reorderable columns can be reordered by dragging their header.

12.5.4 New :x-adjust initarg for capi:multi-column-list-panel

The class capi:multi-column-list-panel has a new initarg :x-adjust, which provides the default value of the :adjust keyword in the column specifications. Its value must be a list of the same length as the :columns initarg.

12.5.5 Specifying the initial selection in capi:prompt-with-list

To specify the initial selection in capi:prompt-with-list, you can supply the keyword arguments :selection, :selected-item or :selected-items. These keywords were present in previous releases but not documented.

12.5.6 Menus can now display with both images and text on Microsoft Windows

The class capi:menu now supports display of both images and text on Microsoft Windows, like it did in previous releases for GTK+ and Cocoa.

12.5.7 Support for dark themes in capi:interface

The class capi:interface has new initargs :color-mode and :color-mode-callback and accessors capi:top-level-interface-color-mode and capi:top-level-interface-color-mode-callback to support dark themes and application-defined changes based on the theme.

The new function capi:top-level-interface-dark-mode-p can be used to detect when an interface is using a dark themes.

12.5.8 Support for dark themes in capi:set-editor-parenthesis-colors

The function capi:set-editor-parenthesis-colors now has a keyword argument :dark-background-colors, which is a list of colors to use for parentheses when the background is dark.

12.5.9 Support for dark themes in capi:stacked-tree

The default colors used by the class capi:stacked-tree change when a dark theme is used. If specify colors or color-function, then you may need to take special action.

12.5.10 New capi:rich-text-pane callback on Windows called when the user clicks a link

The class capi:rich-text-pane has a new initarg :link-callback, which is a function to be called if the text contains a hyperlink and the user click on it. This is only implemented on Windows.

12.5.11 Adding additional filters in capi:list-panel and capi:filtering-layout

The class capi:list-panel has a new initarg :filter-added-filters, which adds additional filters that apply to the items of the panel.

The class capi:filtering-layout has a new initarg :added-filters that does the same thing.

The function capi:filtering-layout-match-object-and-exclude-p returns an extra value, which is a list of the added filters that have been selected by the user.

12.5.12 Coordinates for keyboard events in the input model take account of scrolling

The callbacks in the input-model of a capi:output-pane are called with the coordinates of the pointer. In previous releases, the coordinates that are passed to callbacks of characters and keys did not take into account scrolling on some platforms. On the other hand, callbacks associated with mouse events (button clicks and motion) always took scrolling into account. In LispWorks 8.0, the coordinates that are passed to callbacks of characters and keys always take into account of scrolling the same way as mouse event callbacks.

That means that, by default (when :pane-can-scroll is nil in an capi:output-pane), the coordinates that the callbacks get when the pointer is on some graphic element match the coordinates that were used to draw the element (assuming there is no graphics transform).

12.5.13 capi:current-pointer-position always takes account of scrolling in capi:output-pane

The coordinates that the function capi:current-pointer-position returns when called with a capi:output-pane now take account of scrolling on all platforms. In previous releases, some platforms did not take account of scrolling.

12.5.14 Forcing scroll bars to be visible on macOS

The class capi:output-pane has a new initarg :scroll-bar-type that allows you to force the scroll bars to be visible on macOS regardless of the setting in the System Preferences.


Release Notes and Installation Guide - 01 Dec 2021 19:38:49