A widget's style (font) is only set after the widget has been
packed and inherits relevant information from the top-level window.
`set_size_request_to_display_given_text()` produces incorrect
results when it is called for widgets without a top-level
(here ARDOUR_UI::setup_windows() _main_window.add(), changes the
font from "Sans 11" to "Sans 9" for ArdourDropdowns).
`set_size_request_to_display_given_text()` must subscribe to
`signal_style_changed()`, however in case of ArdourButton UI-scaling
of elements also needs to be taken into account. It is preferable
to allow for multiple sizing-texts directly.
A Pango::Layout created by Gtk::Widget::get_pango_context ()
does not have any font set. The Font is inherited from the
layout's context.
The actual font is set when the layout is used in
on_expose_event() via get_window ()->create_cairo_context ().
In some cases we rely on the font-size to calculate the widget's
size before rendering. At this point in time there is no drawing
context from which to inherit the style.
Furthermore, even after a call to `ensure_style()` in the c'tor
of a Widget get_font() simply returns the default value.
All Widgets that rely an Pango::Layout font size during
size-requests have to explicitly set the font.
This fixes various overlarge buttons with the initial default layout.
Actions for hide/show/attach/detach tabbables use hard-coded names which are not
translated. Using Tabbable/WindowProxy::name() to lookup the action will fail,
since the name can be translated. This changes just removes the option to not
provide a menu-name when creating these objects, and uses the name menu-name
when looking up an action by name
This fixes an issue with scroll-wheel control which uses `get_active()`.
It work around an issue with gtkmm:
const MenuItem* get_active () const
void set_active (guint index)
and MenuList::activate_item() not emitting activate_item().
Add option to use ArduorButton as standalone Toggle/Checkbox.
Usually ArdourButton relegates this to Actions or is backed by Config.
This allows to use the Button as standalone Toggle, get_active()
It should maybe be a derived Class, but ArdourButton is already beyond
that..