LibreOffice Module vcl (master)  1
salvtables.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  */
9 #pragma once
10 
11 #include <vcl/weld.hxx>
12 #include <vcl/svapp.hxx>
13 #include <vcl/syswin.hxx>
14 #include <vcl/settings.hxx>
15 #include <vcl/virdev.hxx>
16 #include <vcl/ctrl.hxx>
17 #include <vcl/toolkit/edit.hxx>
18 #include <vcl/formatter.hxx>
19 #include <vcl/toolkit/spinfld.hxx>
20 #include <vcl/toolkit/fixed.hxx>
21 #include <vcl/toolkit/lstbox.hxx>
22 #include <vcl/toolkit/menubtn.hxx>
23 #include <vcl/toolkit/combobox.hxx>
24 #include <vcl/tabctrl.hxx>
25 #include <vcl/layout.hxx>
26 #include <vcl/toolkit/svtabbx.hxx>
27 #include <vcl/toolkit/svlbitm.hxx>
28 #include <o3tl/sorted_vector.hxx>
29 #include "iconview.hxx"
30 #include "listbox.hxx"
31 #include "messagedialog.hxx"
32 
34 {
35 protected:
36  std::unique_ptr<VclBuilder> m_xBuilder;
38 
39 public:
40  SalInstanceBuilder(vcl::Window* pParent, const OUString& rUIRoot, const OUString& rUIFile,
41  const css::uno::Reference<css::frame::XFrame>& rFrame
42  = css::uno::Reference<css::frame::XFrame>());
43 
44  virtual std::unique_ptr<weld::MessageDialog> weld_message_dialog(const OString& id) override;
45 
46  virtual std::unique_ptr<weld::Dialog> weld_dialog(const OString& id) override;
47 
48  virtual std::unique_ptr<weld::Assistant> weld_assistant(const OString& id) override;
49 
50  virtual std::unique_ptr<weld::Window> create_screenshot_window() override;
51 
52  virtual std::unique_ptr<weld::Widget> weld_widget(const OString& id) override;
53 
54  virtual std::unique_ptr<weld::Container> weld_container(const OString& id) override;
55 
56  virtual std::unique_ptr<weld::Box> weld_box(const OString& id) override;
57 
58  virtual std::unique_ptr<weld::Paned> weld_paned(const OString& id) override;
59 
60  virtual std::unique_ptr<weld::Frame> weld_frame(const OString& id) override;
61 
62  virtual std::unique_ptr<weld::ScrolledWindow>
63  weld_scrolled_window(const OString& id, bool bUserManagedScrolling = false) override;
64 
65  virtual std::unique_ptr<weld::Notebook> weld_notebook(const OString& id) override;
66 
67  virtual std::unique_ptr<weld::Button> weld_button(const OString& id) override;
68 
69  virtual std::unique_ptr<weld::MenuButton> weld_menu_button(const OString& id) override;
70 
71  virtual std::unique_ptr<weld::MenuToggleButton>
72  weld_menu_toggle_button(const OString& id) override;
73 
74  virtual std::unique_ptr<weld::LinkButton> weld_link_button(const OString& id) override;
75 
76  virtual std::unique_ptr<weld::ToggleButton> weld_toggle_button(const OString& id) override;
77 
78  virtual std::unique_ptr<weld::RadioButton> weld_radio_button(const OString& id) override;
79 
80  virtual std::unique_ptr<weld::CheckButton> weld_check_button(const OString& id) override;
81 
82  virtual std::unique_ptr<weld::Scale> weld_scale(const OString& id) override;
83 
84  virtual std::unique_ptr<weld::ProgressBar> weld_progress_bar(const OString& id) override;
85 
86  virtual std::unique_ptr<weld::Spinner> weld_spinner(const OString& id) override;
87 
88  virtual std::unique_ptr<weld::Image> weld_image(const OString& id) override;
89 
90  virtual std::unique_ptr<weld::Calendar> weld_calendar(const OString& id) override;
91 
92  virtual std::unique_ptr<weld::Entry> weld_entry(const OString& id) override;
93 
94  virtual std::unique_ptr<weld::SpinButton> weld_spin_button(const OString& id) override;
95 
96  virtual std::unique_ptr<weld::MetricSpinButton>
97  weld_metric_spin_button(const OString& id, FieldUnit eUnit) override;
98 
99  virtual std::unique_ptr<weld::FormattedSpinButton>
100  weld_formatted_spin_button(const OString& id) override;
101 
102  virtual std::unique_ptr<weld::ComboBox> weld_combo_box(const OString& id) override;
103 
104  virtual std::unique_ptr<weld::EntryTreeView>
105  weld_entry_tree_view(const OString& containerid, const OString& entryid,
106  const OString& treeviewid) override;
107 
108  virtual std::unique_ptr<weld::TreeView> weld_tree_view(const OString& id) override;
109 
110  virtual std::unique_ptr<weld::IconView> weld_icon_view(const OString& id) override;
111 
112  virtual std::unique_ptr<weld::Label> weld_label(const OString& id) override;
113 
114  virtual std::unique_ptr<weld::TextView> weld_text_view(const OString& id) override;
115 
116  virtual std::unique_ptr<weld::Expander> weld_expander(const OString& id) override;
117 
118  virtual std::unique_ptr<weld::DrawingArea>
119  weld_drawing_area(const OString& id, const a11yref& rA11yImpl = nullptr,
120  FactoryFunction pUITestFactoryFunction = nullptr,
121  void* pUserData = nullptr) override;
122 
123  virtual std::unique_ptr<weld::Menu> weld_menu(const OString& id) override;
124 
125  virtual std::unique_ptr<weld::Popover> weld_popover(const OString& id) override;
126 
127  virtual std::unique_ptr<weld::Toolbar> weld_toolbar(const OString& id) override;
128 
129  virtual std::unique_ptr<weld::SizeGroup> create_size_group() override;
130 
131  OString get_current_page_help_id() const;
132 
133  virtual ~SalInstanceBuilder() override;
134 };
135 
136 class SAL_DLLPUBLIC_RTTI SalInstanceMenu final : public weld::Menu
137 {
138 private:
140 
142  sal_uInt16 m_nLastId;
143 
144  DECL_LINK(SelectMenuHdl, ::Menu*, bool);
145 
146 public:
147  SalInstanceMenu(PopupMenu* pMenu, bool bTakeOwnership);
148  virtual OString popup_at_rect(weld::Widget* pParent, const tools::Rectangle& rRect) override;
149  virtual void set_sensitive(const OString& rIdent, bool bSensitive) override;
150  virtual bool get_sensitive(const OString& rIdent) const override;
151  virtual void set_active(const OString& rIdent, bool bActive) override;
152  virtual bool get_active(const OString& rIdent) const override;
153  virtual void set_label(const OString& rIdent, const OUString& rLabel) override;
154  virtual OUString get_label(const OString& rIdent) const override;
155  virtual void set_visible(const OString& rIdent, bool bShow) override;
156  virtual void clear() override;
157  virtual void insert(int pos, const OUString& rId, const OUString& rStr,
158  const OUString* pIconName, VirtualDevice* pImageSurface,
159  const css::uno::Reference<css::graphic::XGraphic>& rImage,
160  TriState eCheckRadioFalse) override;
161  virtual void insert_separator(int pos, const OUString& rId) override;
162  virtual void remove(const OString& rId) override;
163  virtual OString get_id(int pos) const override;
164  virtual int n_children() const override;
165  PopupMenu* getMenu() const;
166  virtual ~SalInstanceMenu() override;
167 };
168 
169 class SalInstanceWidget : public virtual weld::Widget
170 {
171 protected:
174 
175 private:
176  DECL_LINK(EventListener, VclWindowEvent&, void);
177  DECL_LINK(KeyEventListener, VclWindowEvent&, bool);
178  DECL_LINK(MouseEventListener, VclWindowEvent&, void);
179  DECL_LINK(MnemonicActivateHdl, vcl::Window&, bool);
180 
181  static void DoRecursivePaint(vcl::Window* pWindow, const Point& rPos, OutputDevice& rOutput);
182 
183  const bool m_bTakeOwnership;
189 
190 protected:
191  void ensure_event_listener();
192 
193  // we want the ability to mark key events as handled, so use this variant
194  // for those, we get all keystrokes in this case, so we will need to filter
195  // them later
196  void ensure_key_listener();
197 
198  // we want the ability to know about mouse events that happen in our children
199  // so use this variant, we will need to filter them later
200  void ensure_mouse_listener();
201 
202  bool IsFirstFreeze() const { return m_nFreezeCount == 0; }
203  bool IsLastThaw() const { return m_nFreezeCount == 1; }
204 
205  virtual void HandleEventListener(VclWindowEvent& rEvent);
206  virtual bool HandleKeyEventListener(VclWindowEvent& rEvent);
207  virtual void HandleMouseEventListener(VclWindowEvent& rEvent);
208 
209 public:
210  SalInstanceWidget(vcl::Window* pWidget, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
211 
212  virtual void set_sensitive(bool sensitive) override;
213 
214  virtual bool get_sensitive() const override;
215 
216  virtual bool get_visible() const override;
217 
218  virtual bool is_visible() const override;
219 
220  virtual void set_can_focus(bool bCanFocus) override;
221 
222  virtual void grab_focus() override;
223 
224  virtual bool has_focus() const override;
225 
226  virtual bool is_active() const override;
227 
228  virtual bool has_child_focus() const override;
229 
230  virtual void set_has_default(bool has_default) override;
231 
232  virtual bool get_has_default() const override;
233 
234  virtual void show() override;
235 
236  virtual void hide() override;
237 
238  virtual void set_size_request(int nWidth, int nHeight) override;
239 
240  virtual Size get_size_request() const override;
241 
242  virtual Size get_preferred_size() const override;
243 
244  virtual float get_approximate_digit_width() const override;
245 
246  virtual int get_text_height() const override;
247 
248  virtual Size get_pixel_size(const OUString& rText) const override;
249 
250  virtual vcl::Font get_font() override;
251 
252  virtual OString get_buildable_name() const override;
253 
254  virtual void set_buildable_name(const OString& rId) override;
255 
256  virtual void set_help_id(const OString& rId) override;
257 
258  virtual OString get_help_id() const override;
259 
260  virtual void set_grid_left_attach(int nAttach) override;
261 
262  virtual int get_grid_left_attach() const override;
263 
264  virtual void set_grid_width(int nCols) override;
265 
266  virtual void set_grid_top_attach(int nAttach) override;
267 
268  virtual int get_grid_top_attach() const override;
269 
270  virtual void set_hexpand(bool bExpand) override;
271 
272  virtual bool get_hexpand() const override;
273 
274  virtual void set_vexpand(bool bExpand) override;
275 
276  virtual bool get_vexpand() const override;
277 
278  virtual void set_margin_top(int nMargin) override;
279 
280  virtual void set_margin_bottom(int nMargin) override;
281 
282  virtual void set_margin_start(int nMargin) override;
283 
284  virtual void set_margin_end(int nMargin) override;
285 
286  virtual int get_margin_top() const override;
287 
288  virtual int get_margin_bottom() const override;
289 
290  virtual int get_margin_start() const override;
291 
292  virtual int get_margin_end() const override;
293 
294  virtual void set_accessible_name(const OUString& rName) override;
295 
296  virtual void set_accessible_description(const OUString& rDescription) override;
297 
298  virtual OUString get_accessible_name() const override;
299 
300  virtual OUString get_accessible_description() const override;
301 
302  virtual void set_accessible_relation_labeled_by(weld::Widget* pLabel) override;
303 
304  virtual void set_accessible_relation_label_for(weld::Widget* pLabeled) override;
305 
306  virtual void set_tooltip_text(const OUString& rTip) override;
307 
308  virtual OUString get_tooltip_text() const override;
309 
310  virtual void connect_focus_in(const Link<Widget&, void>& rLink) override;
311 
312  virtual void connect_mnemonic_activate(const Link<Widget&, bool>& rLink) override;
313 
314  virtual void connect_focus_out(const Link<Widget&, void>& rLink) override;
315 
316  virtual void connect_size_allocate(const Link<const Size&, void>& rLink) override;
317 
318  virtual void connect_mouse_press(const Link<const MouseEvent&, bool>& rLink) override;
319 
320  virtual void connect_mouse_move(const Link<const MouseEvent&, bool>& rLink) override;
321 
322  virtual void connect_mouse_release(const Link<const MouseEvent&, bool>& rLink) override;
323 
324  virtual void connect_key_press(const Link<const KeyEvent&, bool>& rLink) override;
325 
326  virtual void connect_key_release(const Link<const KeyEvent&, bool>& rLink) override;
327 
328  virtual bool get_extents_relative_to(const Widget& rRelative, int& x, int& y, int& width,
329  int& height) const override;
330 
331  virtual void grab_add() override;
332 
333  virtual bool has_grab() const override;
334 
335  virtual void grab_remove() override;
336 
337  virtual bool get_direction() const override;
338 
339  virtual void set_direction(bool bRTL) override;
340 
341  virtual void freeze() override;
342 
343  virtual void thaw() override;
344 
345  virtual void set_busy_cursor(bool bBusy) override;
346 
347  virtual std::unique_ptr<weld::Container> weld_parent() const override;
348 
349  virtual ~SalInstanceWidget() override;
350 
351  vcl::Window* getWidget() const;
352 
353  void disable_notify_events();
354 
355  bool notify_events_disabled();
356 
357  void enable_notify_events();
358 
359  virtual void queue_resize() override;
360 
361  virtual void help_hierarchy_foreach(const std::function<bool(const OString&)>& func) override;
362 
363  virtual OUString strip_mnemonic(const OUString& rLabel) const override;
364 
365  virtual VclPtr<VirtualDevice> create_virtual_device() const override;
366 
367  virtual css::uno::Reference<css::datatransfer::dnd::XDropTarget> get_drop_target() override;
368  virtual css::uno::Reference<css::datatransfer::clipboard::XClipboard>
369  get_clipboard() const override;
370 
371  virtual void connect_get_property_tree(const Link<tools::JsonWriter&, void>& rLink) override;
372 
373  virtual void get_property_tree(tools::JsonWriter& rJsonWriter) override;
374 
375  virtual void set_stack_background() override;
376 
377  virtual void set_title_background() override;
378 
379  virtual void set_toolbar_background() override;
380 
381  virtual void set_highlight_background() override;
382 
383  virtual void set_background(const Color& rColor) override;
384 
385  virtual void draw(OutputDevice& rOutput, const Point& rPos, const Size& rSizePixel) override;
386 
388 };
389 
390 class SalInstanceLabel : public SalInstanceWidget, public virtual weld::Label
391 {
392 private:
393  // Control instead of FixedText so we can also use this for
394  // SelectableFixedText which is derived from Edit. We just typically need
395  // [G|S]etText which exists in their shared baseclass
397 
398 public:
399  SalInstanceLabel(Control* pLabel, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
400 
401  virtual void set_label(const OUString& rText) override;
402 
403  virtual OUString get_label() const override;
404 
405  virtual void set_mnemonic_widget(Widget* pTarget) override;
406 
407  virtual void set_label_type(weld::LabelType eType) override;
408 
409  virtual void set_font(const vcl::Font& rFont) override;
410 
411  virtual void set_font_color(const Color& rColor) override;
412 };
413 
415 {
416 protected:
418 
419 private:
420  void implResetDefault(const vcl::Window* _pWindow);
421 
422 public:
423  SalInstanceContainer(vcl::Window* pContainer, SalInstanceBuilder* pBuilder,
424  bool bTakeOwnership);
425  virtual void HandleEventListener(VclWindowEvent& rEvent) override;
426  virtual void connect_container_focus_changed(const Link<Container&, void>& rLink) override;
427  virtual void child_grab_focus() override;
428  virtual void move(weld::Widget* pWidget, weld::Container* pNewParent) override;
429  virtual void recursively_unset_default_buttons() override;
430  virtual css::uno::Reference<css::awt::XWindow> CreateChildFrame() override;
431 };
432 
434 {
435 private:
437 
438  DECL_LINK(HelpHdl, vcl::Window&, bool);
439 
440  void override_child_help(vcl::Window* pParent);
441 
442  void clear_child_help(vcl::Window* pParent);
443 
444 public:
445  SalInstanceWindow(vcl::Window* pWindow, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
446 
447  virtual void set_title(const OUString& rTitle) override;
448 
449  virtual OUString get_title() const override;
450 
451  void help();
452 
453  virtual css::uno::Reference<css::awt::XWindow> GetXWindow() override;
454 
455  virtual void resize_to_request() override;
456 
457  virtual void set_modal(bool bModal) override;
458 
459  virtual bool get_modal() const override;
460 
461  virtual void window_move(int x, int y) override;
462 
463  virtual Size get_size() const override;
464 
465  virtual Point get_position() const override;
466 
467  virtual tools::Rectangle get_monitor_workarea() const override;
468 
469  virtual void set_centered_on_parent(bool /*bTrackGeometryRequests*/) override;
470 
471  virtual bool get_resizable() const override;
472 
473  virtual bool has_toplevel_focus() const override;
474 
475  virtual void present() override;
476 
477  virtual void set_window_state(const OString& rStr) override;
478 
479  virtual OString get_window_state(WindowStateMask nMask) const override;
480 
481  virtual SystemEnvData get_system_data() const override;
482 
484 
485  virtual VclPtr<VirtualDevice> screenshot() override;
486 
487  virtual ~SalInstanceWindow() override;
488 };
489 
490 class SalInstanceDialog : public SalInstanceWindow, public virtual weld::Dialog
491 {
492 private:
494 
495  // for calc ref dialog that shrink to range selection widgets and resize back
497  std::vector<VclPtr<vcl::Window>> m_aHiddenWidgets; // vector of hidden Controls
498  tools::Long m_nOldEditWidthReq; // Original width request of the input field
499  sal_Int32 m_nOldBorderWidth; // border width for expanded dialog
500 
501  DECL_LINK(PopupScreenShotMenuHdl, const CommandEvent&, bool);
502 
503 public:
504  SalInstanceDialog(::Dialog* pDialog, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
505 
506  virtual bool runAsync(std::shared_ptr<weld::DialogController> aOwner,
507  const std::function<void(sal_Int32)>& rEndDialogFn) override;
508 
509  virtual bool runAsync(std::shared_ptr<Dialog> const& rxSelf,
510  const std::function<void(sal_Int32)>& rEndDialogFn) override;
511 
512  virtual void collapse(weld::Widget* pEdit, weld::Widget* pButton) override;
513 
514  virtual void undo_collapse() override;
515 
516  virtual void
518 
519  virtual int run() override;
520 
521  virtual void response(int nResponse) override;
522 
523  virtual void add_button(const OUString& rText, int nResponse,
524  const OString& rHelpId = OString()) override;
525 
526  virtual void set_modal(bool bModal) override;
527 
528  virtual bool get_modal() const override;
529 
530  virtual weld::Button* weld_widget_for_response(int nResponse) override;
531 
532  virtual void set_default_response(int nResponse) override;
533 
534  virtual weld::Container* weld_content_area() override;
535 };
536 
537 class WeldTextFilter final : public TextFilter
538 {
539 private:
541 
542 public:
543  WeldTextFilter(Link<OUString&, bool>& rInsertTextHdl);
544 
545  virtual OUString filter(const OUString& rText) override;
546 };
547 
548 class SalInstanceEntry : public SalInstanceWidget, public virtual weld::Entry
549 {
550 private:
552 
553  DECL_LINK(ChangeHdl, Edit&, void);
554  DECL_LINK(CursorListener, VclWindowEvent&, void);
555  DECL_LINK(ActivateHdl, Edit&, bool);
556 
558 
559 public:
560  SalInstanceEntry(::Edit* pEntry, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
561 
562  virtual void set_text(const OUString& rText) override;
563 
564  virtual OUString get_text() const override;
565 
566  virtual void set_width_chars(int nChars) override;
567 
568  virtual int get_width_chars() const override;
569 
570  virtual void set_max_length(int nChars) override;
571 
572  virtual void select_region(int nStartPos, int nEndPos) override;
573 
574  bool get_selection_bounds(int& rStartPos, int& rEndPos) override;
575 
576  virtual void replace_selection(const OUString& rText) override;
577 
578  virtual void set_position(int nCursorPos) override;
579 
580  virtual int get_position() const override;
581 
582  virtual void set_editable(bool bEditable) override;
583 
584  virtual bool get_editable() const override;
585 
586  virtual void set_overwrite_mode(bool bOn) override;
587 
588  virtual bool get_overwrite_mode() const override;
589 
590  virtual void set_message_type(weld::EntryMessageType eType) override;
591 
592  virtual void set_font(const vcl::Font& rFont) override;
593 
594  virtual void set_font_color(const Color& rColor) override;
595 
596  virtual void connect_cursor_position(const Link<Entry&, void>& rLink) override;
597 
598  virtual void set_placeholder_text(const OUString& rText) override;
599 
600  Edit& getEntry();
601 
602  void fire_signal_changed();
603 
604  virtual void cut_clipboard() override;
605 
606  virtual void copy_clipboard() override;
607 
608  virtual void paste_clipboard() override;
609 
610  virtual void set_alignment(TxtAlign eXAlign) override;
611 
612  virtual ~SalInstanceEntry() override;
613 };
614 
616 {
617 private:
620 
621  DECL_LINK(UpDownHdl, SpinField&, void);
622  DECL_LINK(LoseFocusHdl, Control&, void);
623  DECL_LINK(OutputHdl, LinkParamNone*, bool);
624  DECL_LINK(InputHdl, sal_Int64*, TriState);
625  DECL_LINK(ActivateHdl, Edit&, bool);
626 
627  double toField(int nValue) const;
628 
629  int fromField(double fValue) const;
630 
631 public:
633  bool bTakeOwnership);
634 
635  virtual int get_value() const override;
636 
637  virtual void set_value(int value) override;
638 
639  virtual void set_range(int min, int max) override;
640 
641  virtual void get_range(int& min, int& max) const override;
642 
643  virtual void set_increments(int step, int /*page*/) override;
644 
645  virtual void get_increments(int& step, int& page) const override;
646 
647  virtual void set_digits(unsigned int digits) override;
648 
649  // SpinButton may be comprised of multiple subwidgets, consider the lot as
650  // one thing for focus
651  virtual bool has_focus() const override;
652 
653  //off by default for direct SpinButtons, MetricSpinButton enables it
654  void SetUseThousandSep();
655 
656  virtual unsigned int get_digits() const override;
657 
658  virtual ~SalInstanceSpinButton() override;
659 };
660 
661 //ComboBox and ListBox have similar apis, ComboBoxes in LibreOffice have an edit box and ListBoxes
662 //don't. This distinction isn't there in Gtk. Use a template to sort this problem out.
663 template <class vcl_type>
665 {
666 protected:
667  // owner for ListBox/ComboBox UserData
668  std::vector<std::shared_ptr<OUString>> m_aUserData;
672 
673 public:
674  SalInstanceComboBox(vcl_type* pComboBox, SalInstanceBuilder* pBuilder, bool bTakeOwnership)
675  : SalInstanceWidget(pComboBox, pBuilder, bTakeOwnership)
676  , m_xComboBox(pComboBox)
677  {
678  }
679 
680  virtual int get_active() const override
681  {
682  const sal_Int32 nRet = m_xComboBox->GetSelectedEntryPos();
683  if (nRet == LISTBOX_ENTRY_NOTFOUND)
684  return -1;
685  return nRet;
686  }
687 
688  const OUString* getEntryData(int index) const
689  {
690  return static_cast<const OUString*>(m_xComboBox->GetEntryData(index));
691  }
692 
693  // ComboBoxes are comprised of multiple subwidgets, consider the lot as
694  // one thing for focus
695  virtual bool has_focus() const override
696  {
697  return m_xWidget->HasChildPathFocus()
698  || (m_xMenuButton && (m_xMenuButton->HasFocus() || m_xMenuButton->InPopupMode()));
699  }
700 
701  virtual OUString get_active_id() const override
702  {
703  sal_Int32 nPos = m_xComboBox->GetSelectedEntryPos();
704  const OUString* pRet;
705  if (nPos != LISTBOX_ENTRY_NOTFOUND)
706  pRet = getEntryData(m_xComboBox->GetSelectedEntryPos());
707  else
708  pRet = nullptr;
709  if (!pRet)
710  return OUString();
711  return *pRet;
712  }
713 
714  virtual void set_active_id(const OUString& rStr) override
715  {
716  for (int i = 0; i < get_count(); ++i)
717  {
718  const OUString* pId = getEntryData(i);
719  if (!pId)
720  continue;
721  if (*pId == rStr)
722  m_xComboBox->SelectEntryPos(i);
723  }
724  }
725 
726  virtual void set_active(int pos) override
727  {
728  if (pos == -1)
729  {
730  m_xComboBox->SetNoSelection();
731  return;
732  }
733  m_xComboBox->SelectEntryPos(pos);
734  }
735 
736  virtual OUString get_text(int pos) const override { return m_xComboBox->GetEntry(pos); }
737 
738  virtual OUString get_id(int pos) const override
739  {
740  const OUString* pRet = getEntryData(pos);
741  if (!pRet)
742  return OUString();
743  return *pRet;
744  }
745 
746  virtual void set_id(int row, const OUString& rId) override
747  {
748  m_aUserData.emplace_back(std::make_unique<OUString>(rId));
749  m_xComboBox->SetEntryData(row, m_aUserData.back().get());
750  }
751 
752  virtual void insert_vector(const std::vector<weld::ComboBoxEntry>& rItems,
753  bool bKeepExisting) override
754  {
755  freeze();
756  if (!bKeepExisting)
757  clear();
758  for (const auto& rItem : rItems)
759  {
760  insert(-1, rItem.sString, rItem.sId.isEmpty() ? nullptr : &rItem.sId,
761  rItem.sImage.isEmpty() ? nullptr : &rItem.sImage, nullptr);
762  }
763  thaw();
764  }
765 
766  virtual int get_count() const override { return m_xComboBox->GetEntryCount(); }
767 
768  virtual int find_text(const OUString& rStr) const override
769  {
770  const sal_Int32 nRet = m_xComboBox->GetEntryPos(rStr);
771  if (nRet == LISTBOX_ENTRY_NOTFOUND)
772  return -1;
773  return nRet;
774  }
775 
776  virtual int find_id(const OUString& rStr) const override
777  {
778  for (int i = 0; i < get_count(); ++i)
779  {
780  const OUString* pId = getEntryData(i);
781  if (!pId)
782  continue;
783  if (*pId == rStr)
784  return i;
785  }
786  return -1;
787  }
788 
789  virtual void clear() override
790  {
791  m_xComboBox->Clear();
792  m_aUserData.clear();
793  }
794 
795  virtual void make_sorted() override
796  {
797  m_xComboBox->SetStyle(m_xComboBox->GetStyle() | WB_SORT);
798  }
799 
800  virtual bool get_popup_shown() const override { return m_xComboBox->IsInDropDown(); }
801 
802  virtual void connect_popup_toggled(const Link<ComboBox&, void>& rLink) override
803  {
806  }
807 
809  {
810  vcl::RenderContext* pRenderContext = pEvent->GetRenderContext();
811  auto nPos = pEvent->GetItemId();
812  const tools::Rectangle& rRect = pEvent->GetRect();
813  const OUString sId = get_id(nPos);
814  signal_custom_render(*pRenderContext, rRect, pEvent->IsSelected(), sId);
815  m_xComboBox->DrawEntry(*pEvent); // draw separator
816 
817  if (m_xMenuButton && m_xMenuButton->IsVisible() && m_sMenuButtonRow == sId)
818  {
819  vcl::Window* pEventWindow = m_xComboBox->GetMainWindow();
820  if (m_xMenuButton->GetParent() != pEventWindow)
821  m_xMenuButton->SetParent(pEventWindow);
823  m_xMenuButton->SetSizePixel(Size(nButtonWidth, rRect.GetHeight()));
824  m_xMenuButton->SetPosPixel(Point(rRect.GetWidth() - nButtonWidth, rRect.Top()));
825  }
826  }
827 
829  {
830  auto xRet = VclPtr<VirtualDevice>::Create();
831  xRet->SetBackground(Application::GetSettings().GetStyleSettings().GetFieldColor());
832  return xRet;
833  }
834 
835  virtual void set_item_menu(const OString& rIdent, weld::Menu* pMenu) override
836  {
837  SalInstanceMenu* pInstanceMenu = dynamic_cast<SalInstanceMenu*>(pMenu);
838 
839  PopupMenu* pPopup = pInstanceMenu ? pInstanceMenu->getMenu() : nullptr;
840 
841  if (!m_xMenuButton)
842  m_xMenuButton
844 
845  m_xMenuButton->SetPopupMenu(pPopup);
846  m_xMenuButton->Show(pPopup != nullptr);
847  m_sMenuButtonRow = OUString::fromUtf8(rIdent);
848  }
849 
850  int get_menu_button_width() const override
851  {
853  return 20 * (pDefault ? pDefault->GetDPIScaleFactor() : 1.0);
854  }
855 
857  {
858  if (rEvent.GetId() == VclEventId::DropdownPreOpen
859  || rEvent.GetId() == VclEventId::DropdownClose)
860  {
862  return;
863  }
865  }
866 };
867 
869 {
870 private:
871  DECL_LINK(SelectHdl, ListBox&, void);
872 
873 public:
875  bool bTakeOwnership);
876 
877  virtual OUString get_active_text() const override;
878 
879  virtual void remove(int pos) override;
880 
881  virtual void insert(int pos, const OUString& rStr, const OUString* pId,
882  const OUString* pIconName, VirtualDevice* pImageSurface) override;
883 
884  virtual void insert_separator(int pos, const OUString& /*rId*/) override;
885 
886  virtual bool has_entry() const override;
887 
888  virtual bool changed_by_direct_pick() const override;
889 
890  virtual void set_entry_message_type(weld::EntryMessageType /*eType*/) override;
891 
892  virtual void set_entry_text(const OUString& /*rText*/) override;
893 
894  virtual void select_entry_region(int /*nStartPos*/, int /*nEndPos*/) override;
895 
896  virtual bool get_entry_selection_bounds(int& /*rStartPos*/, int& /*rEndPos*/) override;
897 
898  virtual void set_entry_width_chars(int /*nChars*/) override;
899 
900  virtual void set_entry_max_length(int /*nChars*/) override;
901 
902  virtual void set_entry_completion(bool, bool bCaseSensitive = false) override;
903 
904  virtual void set_entry_placeholder_text(const OUString&) override;
905 
906  virtual void set_entry_editable(bool bEditable) override;
907 
908  virtual void cut_entry_clipboard() override;
909 
910  virtual void copy_entry_clipboard() override;
911 
912  virtual void paste_entry_clipboard() override;
913 
914  virtual void set_entry_font(const vcl::Font&) override;
915 
916  virtual vcl::Font get_entry_font() override;
917 
918  virtual void set_custom_renderer(bool bOn) override;
919 
920  virtual int get_max_mru_count() const override;
921 
922  virtual void set_max_mru_count(int) override;
923 
924  virtual OUString get_mru_entries() const override;
925 
926  virtual void set_mru_entries(const OUString&) override;
927 
928  virtual void HandleEventListener(VclWindowEvent& rEvent) override;
929 
930  virtual ~SalInstanceComboBoxWithoutEdit() override;
931 };
932 
934 {
935 private:
936  DECL_LINK(ChangeHdl, Edit&, void);
937  DECL_LINK(EntryActivateHdl, Edit&, bool);
938  DECL_LINK(SelectHdl, ::ComboBox&, void);
939  DECL_LINK(UserDrawHdl, UserDrawEvent*, void);
942 
943 public:
945  bool bTakeOwnership);
946 
947  virtual bool has_entry() const override;
948 
949  virtual bool changed_by_direct_pick() const override;
950 
951  virtual void set_entry_message_type(weld::EntryMessageType eType) override;
952 
953  virtual OUString get_active_text() const override;
954 
955  virtual void remove(int pos) override;
956 
957  virtual void insert(int pos, const OUString& rStr, const OUString* pId,
958  const OUString* pIconName, VirtualDevice* pImageSurface) override;
959 
960  virtual void insert_separator(int pos, const OUString& /*rId*/) override;
961 
962  virtual void set_entry_text(const OUString& rText) override;
963 
964  virtual void set_entry_width_chars(int nChars) override;
965 
966  virtual void set_entry_max_length(int nChars) override;
967 
968  virtual void set_entry_completion(bool bEnable, bool bCaseSensitive = false) override;
969 
970  virtual void set_entry_placeholder_text(const OUString& rText) override;
971 
972  virtual void set_entry_editable(bool bEditable) override;
973 
974  virtual void cut_entry_clipboard() override;
975 
976  virtual void copy_entry_clipboard() override;
977 
978  virtual void paste_entry_clipboard() override;
979 
980  virtual void select_entry_region(int nStartPos, int nEndPos) override;
981 
982  virtual bool get_entry_selection_bounds(int& rStartPos, int& rEndPos) override;
983 
984  virtual void set_entry_font(const vcl::Font& rFont) override;
985 
986  virtual vcl::Font get_entry_font() override;
987 
988  virtual void set_custom_renderer(bool bOn) override;
989 
990  virtual int get_max_mru_count() const override;
991 
992  virtual void set_max_mru_count(int nCount) override;
993 
994  virtual OUString get_mru_entries() const override;
995 
996  virtual void set_mru_entries(const OUString& rEntries) override;
997 
998  virtual void HandleEventListener(VclWindowEvent& rEvent) override;
999 
1000  virtual ~SalInstanceComboBoxWithEdit() override;
1001 };
1002 
1003 class SalInstanceButton : public SalInstanceWidget, public virtual weld::Button
1004 {
1005 private:
1008 
1009  DECL_LINK(ClickHdl, ::Button*, void);
1010 
1011 protected:
1012  void set_label_wrap(bool bWrap);
1013 
1014 public:
1015  SalInstanceButton(::Button* pButton, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1016 
1017  virtual void set_label(const OUString& rText) override;
1018 
1019  virtual void set_image(VirtualDevice* pDevice) override;
1020 
1021  virtual void set_image(const css::uno::Reference<css::graphic::XGraphic>& rImage) override;
1022 
1023  virtual void set_from_icon_name(const OUString& rIconName) override;
1024 
1025  virtual OUString get_label() const override;
1026 
1027  virtual void set_font(const vcl::Font& rFont) override;
1028 
1029  virtual void set_custom_button(VirtualDevice* pDevice) override;
1030 
1031  virtual ~SalInstanceButton() override;
1032 };
1033 
1035 {
1036 private:
1038  mutable std::vector<std::shared_ptr<SalInstanceContainer>> m_aPages;
1039  std::map<OString, std::pair<VclPtr<TabPage>, VclPtr<VclGrid>>> m_aAddedPages;
1040 
1041  DECL_LINK(DeactivatePageHdl, TabControl*, bool);
1042  DECL_LINK(ActivatePageHdl, TabControl*, void);
1043 
1044 public:
1045  SalInstanceNotebook(TabControl* pNotebook, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1046 
1047  virtual int get_current_page() const override;
1048 
1049  virtual int get_page_index(const OString& rIdent) const override;
1050 
1051  virtual OString get_page_ident(int nPage) const override;
1052 
1053  virtual OString get_current_page_ident() const override;
1054 
1055  virtual weld::Container* get_page(const OString& rIdent) const override;
1056 
1057  virtual void set_current_page(int nPage) override;
1058 
1059  virtual void set_current_page(const OString& rIdent) override;
1060 
1061  virtual void remove_page(const OString& rIdent) override;
1062 
1063  virtual void insert_page(const OString& rIdent, const OUString& rLabel, int nPos) override;
1064 
1065  virtual int get_n_pages() const override;
1066 
1067  virtual OUString get_tab_label_text(const OString& rIdent) const override;
1068 
1069  virtual void set_tab_label_text(const OString& rIdent, const OUString& rText) override;
1070 
1071  virtual ~SalInstanceNotebook() override;
1072 };
1073 
1075 {
1076 protected:
1078 
1079 public:
1081  bool bTakeOwnership);
1082 
1083  virtual void set_primary_text(const OUString& rText) override;
1084 
1085  virtual OUString get_primary_text() const override;
1086 
1087  virtual void set_secondary_text(const OUString& rText) override;
1088 
1089  virtual OUString get_secondary_text() const override;
1090 
1091  virtual weld::Container* weld_message_area() override;
1092 };
1093 
1095 {
1096 private:
1098 
1099  DECL_LINK(ToggleHdl, CheckBox&, void);
1100 
1101 public:
1102  SalInstanceCheckButton(CheckBox* pButton, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1103 
1104  virtual void set_active(bool active) override;
1105 
1106  virtual bool get_active() const override;
1107 
1108  virtual void set_inconsistent(bool inconsistent) override;
1109 
1110  virtual bool get_inconsistent() const override;
1111 
1112  virtual void set_label(const OUString& rText) override { SalInstanceButton::set_label(rText); }
1113 
1114  virtual OUString get_label() const override { return SalInstanceButton::get_label(); }
1115 
1116  virtual void set_label_wrap(bool wrap) override { SalInstanceButton::set_label_wrap(wrap); }
1117 
1118  virtual ~SalInstanceCheckButton() override;
1119 };
1120 
1122 {
1123 private:
1125 
1126  typedef std::pair<vcl::RenderContext&, const tools::Rectangle&> target_and_area;
1127  DECL_LINK(PaintHdl, target_and_area, void);
1128  DECL_LINK(ResizeHdl, const Size&, void);
1129  DECL_LINK(MousePressHdl, const MouseEvent&, bool);
1130  DECL_LINK(MouseMoveHdl, const MouseEvent&, bool);
1131  DECL_LINK(MouseReleaseHdl, const MouseEvent&, bool);
1132  DECL_LINK(KeyPressHdl, const KeyEvent&, bool);
1133  DECL_LINK(KeyReleaseHdl, const KeyEvent&, bool);
1134  DECL_LINK(StyleUpdatedHdl, VclDrawingArea&, void);
1135  DECL_LINK(CommandHdl, const CommandEvent&, bool);
1136  DECL_LINK(QueryTooltipHdl, tools::Rectangle&, OUString);
1137  DECL_LINK(GetSurroundingHdl, OUString&, int);
1138  DECL_LINK(DeleteSurroundingHdl, const Selection&, bool);
1139  DECL_LINK(StartDragHdl, VclDrawingArea*, bool);
1140 
1141  // SalInstanceWidget has a generic listener for all these
1142  // events, ignore the ones we have specializations for
1143  // in VclDrawingArea
1144  virtual void HandleEventListener(VclWindowEvent& rEvent) override;
1145 
1146  virtual void HandleMouseEventListener(VclWindowEvent& rEvent) override;
1147 
1148  virtual bool HandleKeyEventListener(VclWindowEvent& /*rEvent*/) override;
1149 
1150 public:
1151  SalInstanceDrawingArea(VclDrawingArea* pDrawingArea, SalInstanceBuilder* pBuilder,
1152  const a11yref& rAlly, FactoryFunction pUITestFactoryFunction,
1153  void* pUserData, bool bTakeOwnership);
1154 
1155  virtual void queue_draw() override;
1156 
1157  virtual void queue_draw_area(int x, int y, int width, int height) override;
1158 
1159  virtual void connect_size_allocate(const Link<const Size&, void>& rLink) override;
1160 
1161  virtual void connect_key_press(const Link<const KeyEvent&, bool>& rLink) override;
1162 
1163  virtual void connect_key_release(const Link<const KeyEvent&, bool>& rLink) override;
1164 
1165  virtual void set_cursor(PointerStyle ePointerStyle) override;
1166 
1167  virtual Point get_pointer_position() const override;
1168 
1169  virtual void set_input_context(const InputContext& rInputContext) override;
1170 
1171  virtual void im_context_set_cursor_location(const tools::Rectangle& rCursorRect,
1172  int nExtTextInputWidth) override;
1173 
1174  virtual a11yref get_accessible_parent() override;
1175 
1176  virtual a11yrelationset get_accessible_relation_set() override;
1177 
1178  virtual Point get_accessible_location_on_screen() override;
1179 
1181  sal_uInt8 eDNDConstants) override;
1182 
1183  virtual ~SalInstanceDrawingArea() override;
1184 
1185  virtual OutputDevice& get_ref_device() override;
1186 
1187  virtual void click(const Point& rPos) override;
1188 };
1189 
1191 {
1192 protected:
1194  std::map<ToolBoxItemId, VclPtr<vcl::Window>> m_aFloats;
1195  std::map<ToolBoxItemId, VclPtr<PopupMenu>> m_aMenus;
1196 
1198 
1199  DECL_LINK(ClickHdl, ToolBox*, void);
1200  DECL_LINK(DropdownClick, ToolBox*, void);
1201  DECL_LINK(MenuToggleListener, VclWindowEvent&, void);
1202 
1203 public:
1204  SalInstanceToolbar(ToolBox* pToolBox, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1205 
1206  virtual void set_item_sensitive(const OString& rIdent, bool bSensitive) override;
1207 
1208  virtual bool get_item_sensitive(const OString& rIdent) const override;
1209 
1210  virtual void set_item_visible(const OString& rIdent, bool bVisible) override;
1211 
1212  virtual void set_item_help_id(const OString& rIdent, const OString& rHelpId) override;
1213 
1214  virtual bool get_item_visible(const OString& rIdent) const override;
1215 
1216  virtual void set_item_active(const OString& rIdent, bool bActive) override;
1217 
1218  virtual bool get_item_active(const OString& rIdent) const override;
1219 
1220  void set_menu_item_active(const OString& rIdent, bool bActive) override;
1221 
1222  bool get_menu_item_active(const OString& rIdent) const override;
1223 
1224  virtual void set_item_popover(const OString& rIdent, weld::Widget* pPopover) override;
1225 
1226  virtual void set_item_menu(const OString& rIdent, weld::Menu* pMenu) override;
1227 
1228  virtual void insert_item(int pos, const OUString& rId) override;
1229 
1230  virtual void insert_separator(int pos, const OUString& /*rId*/) override;
1231 
1232  virtual int get_n_items() const override;
1233 
1234  virtual OString get_item_ident(int nIndex) const override;
1235 
1236  virtual void set_item_ident(int nIndex, const OString& rIdent) override;
1237 
1238  virtual void set_item_label(int nIndex, const OUString& rLabel) override;
1239 
1240  virtual OUString get_item_label(const OString& rIdent) const override;
1241 
1242  virtual void set_item_label(const OString& rIdent, const OUString& rLabel) override;
1243 
1244  virtual void set_item_icon_name(const OString& rIdent, const OUString& rIconName) override;
1245 
1246  virtual void set_item_image(const OString& rIdent,
1247  const css::uno::Reference<css::graphic::XGraphic>& rIcon) override;
1248 
1249  virtual void set_item_image(const OString& rIdent, VirtualDevice* pDevice) override;
1250 
1251  virtual void set_item_image(int nIndex,
1252  const css::uno::Reference<css::graphic::XGraphic>& rIcon) override;
1253 
1254  virtual void set_item_tooltip_text(int nIndex, const OUString& rTip) override;
1255 
1256  virtual void set_item_tooltip_text(const OString& rIdent, const OUString& rTip) override;
1257 
1258  virtual OUString get_item_tooltip_text(const OString& rIdent) const override;
1259 
1260  virtual vcl::ImageType get_icon_size() const override;
1261 
1262  virtual void set_icon_size(vcl::ImageType eType) override;
1263 
1264  virtual sal_uInt16 get_modifier_state() const override;
1265 
1266  virtual int get_drop_index(const Point& rPoint) const override;
1267 
1268  virtual ~SalInstanceToolbar() override;
1269 };
1270 
1272 {
1273 private:
1276 
1277  DECL_LINK(ChangeHdl, Edit&, void);
1278  DECL_LINK(VscrollHdl, ScrollBar*, void);
1279  DECL_LINK(CursorListener, VclWindowEvent&, void);
1280 
1281 public:
1283  bool bTakeOwnership);
1284 
1285  virtual void set_text(const OUString& rText) override;
1286 
1287  virtual void replace_selection(const OUString& rText) override;
1288 
1289  virtual OUString get_text() const override;
1290 
1291  bool get_selection_bounds(int& rStartPos, int& rEndPos) override;
1292 
1293  virtual void select_region(int nStartPos, int nEndPos) override;
1294 
1295  virtual void set_editable(bool bEditable) override;
1296  virtual bool get_editable() const override;
1297  virtual void set_max_length(int nChars) override;
1298 
1299  virtual void set_monospace(bool bMonospace) override;
1300 
1301  virtual void set_font_color(const Color& rColor) override;
1302 
1303  virtual void connect_cursor_position(const Link<TextView&, void>& rLink) override;
1304 
1305  virtual bool can_move_cursor_with_up() const override;
1306 
1307  virtual bool can_move_cursor_with_down() const override;
1308 
1309  virtual void cut_clipboard() override;
1310 
1311  virtual void copy_clipboard() override;
1312 
1313  virtual void paste_clipboard() override;
1314 
1315  virtual void set_alignment(TxtAlign eXAlign) override;
1316 
1317  virtual int vadjustment_get_value() const override;
1318 
1319  virtual void vadjustment_set_value(int value) override;
1320 
1321  virtual int vadjustment_get_upper() const override;
1322 
1323  virtual int vadjustment_get_lower() const override;
1324 
1325  virtual int vadjustment_get_page_size() const override;
1326 
1327  virtual bool has_focus() const override;
1328 
1329  virtual ~SalInstanceTextView() override;
1330 };
1331 
1333 {
1335  : iter(pOrig ? pOrig->iter : nullptr)
1336  {
1337  }
1339  : iter(pIter)
1340  {
1341  }
1342  virtual bool equal(const TreeIter& rOther) const override
1343  {
1344  return iter == static_cast<const SalInstanceTreeIter&>(rOther).iter;
1345  }
1347 };
1348 
1350 {
1351 protected:
1352  // owner for UserData
1353  std::vector<std::unique_ptr<OUString>> m_aUserData;
1357  // currently expanding parent that logically, but not currently physically,
1358  // contain placeholders
1360  // which columns should be custom rendered
1364 
1365  DECL_LINK(SelectHdl, SvTreeListBox*, void);
1366  DECL_LINK(DeSelectHdl, SvTreeListBox*, void);
1367  DECL_LINK(DoubleClickHdl, SvTreeListBox*, bool);
1368  DECL_LINK(ExpandingHdl, SvTreeListBox*, bool);
1369  DECL_LINK(EndDragHdl, HeaderBar*, void);
1370  DECL_LINK(HeaderBarClickedHdl, HeaderBar*, void);
1371  DECL_LINK(ToggleHdl, SvLBoxButtonData*, void);
1372  DECL_LINK(ModelChangedHdl, SvTreeListBox*, void);
1373  DECL_LINK(StartDragHdl, SvTreeListBox*, bool);
1374  DECL_STATIC_LINK(SalInstanceTreeView, FinishDragHdl, SvTreeListBox*, void);
1375  DECL_LINK(EditingEntryHdl, SvTreeListEntry*, bool);
1376  typedef std::pair<SvTreeListEntry*, OUString> IterString;
1377  DECL_LINK(EditedEntryHdl, IterString, bool);
1378  DECL_LINK(VisibleRangeChangedHdl, SvTreeListBox*, void);
1379  DECL_LINK(CompareHdl, const SvSortData&, sal_Int32);
1380  DECL_LINK(PopupMenuHdl, const CommandEvent&, bool);
1381  DECL_LINK(TooltipHdl, const HelpEvent&, bool);
1382  DECL_LINK(CustomRenderHdl, svtree_render_args, void);
1383  DECL_LINK(CustomMeasureHdl, svtree_measure_args, Size);
1384 
1385  // Each row has a cell for the expander image, (and an optional cell for a
1386  // checkbutton if enable_toggle_buttons has been called) which precede
1387  // index 0
1388  int to_internal_model(int col) const;
1389 
1390  int to_external_model(int col) const;
1391 
1392  bool IsDummyEntry(SvTreeListEntry* pEntry) const;
1393 
1395 
1396  static void set_font_color(SvTreeListEntry* pEntry, const Color& rColor);
1397 
1398  void AddStringItem(SvTreeListEntry* pEntry, const OUString& rStr, int nCol);
1399 
1400  void do_insert(const weld::TreeIter* pParent, int pos, const OUString* pStr,
1401  const OUString* pId, const OUString* pIconName,
1402  const VirtualDevice* pImageSurface, bool bChildrenOnDemand, weld::TreeIter* pRet,
1403  bool bIsSeparator);
1404 
1406 
1407  void InvalidateModelEntry(SvTreeListEntry* pEntry);
1408 
1409  void do_set_toggle(SvTreeListEntry* pEntry, TriState eState, int col);
1410 
1411  static TriState do_get_toggle(SvTreeListEntry* pEntry, int col);
1412 
1413  TriState get_toggle(SvTreeListEntry* pEntry, int col) const;
1414 
1415  void set_toggle(SvTreeListEntry* pEntry, TriState eState, int col);
1416 
1417  bool get_text_emphasis(SvTreeListEntry* pEntry, int col) const;
1418 
1419  void set_header_item_width(const std::vector<int>& rWidths);
1420 
1421 public:
1422  SalInstanceTreeView(SvTabListBox* pTreeView, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1423 
1424  virtual void connect_query_tooltip(const Link<const weld::TreeIter&, OUString>& rLink) override;
1425 
1426  virtual void columns_autosize() override;
1427 
1428  virtual void freeze() override;
1429 
1430  virtual void thaw() override;
1431 
1432  virtual void set_column_fixed_widths(const std::vector<int>& rWidths) override;
1433 
1434  virtual void set_column_editables(const std::vector<bool>& rEditables) override;
1435 
1436  virtual void set_centered_column(int nCol) override;
1437 
1438  virtual int get_column_width(int nColumn) const override;
1439 
1440  virtual OUString get_column_title(int nColumn) const override;
1441 
1442  virtual void set_column_title(int nColumn, const OUString& rTitle) override;
1443 
1444  virtual void set_column_custom_renderer(int nColumn, bool bEnable) override;
1445 
1446  virtual void queue_draw() override;
1447 
1448  virtual void show() override;
1449 
1450  virtual void hide() override;
1451 
1452  virtual void insert(const weld::TreeIter* pParent, int pos, const OUString* pStr,
1453  const OUString* pId, const OUString* pIconName,
1454  VirtualDevice* pImageSurface, bool bChildrenOnDemand,
1455  weld::TreeIter* pRet) override;
1456 
1457  virtual void insert_separator(int pos, const OUString& /*rId*/) override;
1458 
1459  virtual void
1460  bulk_insert_for_each(int nSourceCount,
1461  const std::function<void(weld::TreeIter&, int nSourceIndex)>& func,
1462  const weld::TreeIter* pParent = nullptr,
1463  const std::vector<int>* pFixedWidths = nullptr) override;
1464 
1465  virtual void set_font_color(int pos, const Color& rColor) override;
1466 
1467  virtual void set_font_color(const weld::TreeIter& rIter, const Color& rColor) override;
1468 
1469  virtual void remove(int pos) override;
1470 
1471  virtual int find_text(const OUString& rText) const override;
1472 
1473  virtual int find_id(const OUString& rId) const override;
1474 
1475  virtual void swap(int pos1, int pos2) override;
1476 
1477  virtual void clear() override;
1478 
1479  virtual int n_children() const override;
1480 
1481  virtual int iter_n_children(const weld::TreeIter& rIter) const override;
1482 
1483  virtual void select(int pos) override;
1484 
1485  virtual int get_cursor_index() const override;
1486 
1487  virtual void set_cursor(int pos) override;
1488 
1489  virtual void scroll_to_row(int pos) override;
1490 
1491  virtual bool is_selected(int pos) const override;
1492 
1493  virtual void unselect(int pos) override;
1494 
1495  virtual std::vector<int> get_selected_rows() const override;
1496 
1497  OUString get_text(SvTreeListEntry* pEntry, int col) const;
1498 
1499  virtual OUString get_text(int pos, int col = -1) const override;
1500 
1501  void set_text(SvTreeListEntry* pEntry, const OUString& rText, int col);
1502 
1503  virtual void set_text(int pos, const OUString& rText, int col = -1) override;
1504 
1505  void set_sensitive(SvTreeListEntry* pEntry, bool bSensitive, int col);
1506 
1508 
1509  virtual void set_sensitive(int pos, bool bSensitive, int col = -1) override;
1510 
1511  virtual void set_sensitive(const weld::TreeIter& rIter, bool bSensitive, int col = -1) override;
1512 
1513  virtual TriState get_toggle(int pos, int col = -1) const override;
1514 
1515  virtual TriState get_toggle(const weld::TreeIter& rIter, int col = -1) const override;
1516 
1517  virtual void enable_toggle_buttons(weld::ColumnToggleType eType) override;
1518 
1519  virtual void set_toggle(int pos, TriState eState, int col = -1) override;
1520 
1521  virtual void set_toggle(const weld::TreeIter& rIter, TriState eState, int col = -1) override;
1522 
1523  virtual void set_clicks_to_toggle(int nToggleBehavior) override;
1524 
1525  virtual void set_extra_row_indent(const weld::TreeIter& rIter, int nIndentLevel) override;
1526 
1527  void set_text_emphasis(SvTreeListEntry* pEntry, bool bOn, int col = -1);
1528 
1529  virtual void set_text_emphasis(const weld::TreeIter& rIter, bool bOn, int col) override;
1530 
1531  virtual void set_text_emphasis(int pos, bool bOn, int col) override;
1532 
1533  virtual bool get_text_emphasis(const weld::TreeIter& rIter, int col) const override;
1534 
1535  virtual bool get_text_emphasis(int pos, int col) const override;
1536 
1537  void set_text_align(SvTreeListEntry* pEntry, double fAlign, int col);
1538 
1539  virtual void set_text_align(const weld::TreeIter& rIter, double fAlign, int col) override;
1540 
1541  virtual void set_text_align(int pos, double fAlign, int col) override;
1542 
1543  virtual void connect_editing(const Link<const weld::TreeIter&, bool>& rStartLink,
1544  const Link<const iter_string&, bool>& rEndLink) override;
1545 
1546  virtual void start_editing(const weld::TreeIter& rIter) override;
1547 
1548  virtual void end_editing() override;
1549 
1550  void set_image(SvTreeListEntry* pEntry, const Image& rImage, int col);
1551 
1552  virtual void set_image(int pos, const OUString& rImage, int col = -1) override;
1553 
1554  virtual void set_image(int pos, const css::uno::Reference<css::graphic::XGraphic>& rImage,
1555  int col = -1) override;
1556 
1557  virtual void set_image(int pos, VirtualDevice& rImage, int col = -1) override;
1558 
1559  virtual void set_image(const weld::TreeIter& rIter, const OUString& rImage,
1560  int col = -1) override;
1561 
1562  virtual void set_image(const weld::TreeIter& rIter,
1563  const css::uno::Reference<css::graphic::XGraphic>& rImage,
1564  int col = -1) override;
1565 
1566  virtual void set_image(const weld::TreeIter& rIter, VirtualDevice& rImage,
1567  int col = -1) override;
1568 
1569  const OUString* getEntryData(int index) const;
1570 
1571  virtual OUString get_id(int pos) const override;
1572 
1573  void set_id(SvTreeListEntry* pEntry, const OUString& rId);
1574 
1575  virtual void set_id(int pos, const OUString& rId) override;
1576 
1577  virtual int get_selected_index() const override;
1578 
1579  virtual OUString get_selected_text() const override;
1580 
1581  virtual OUString get_selected_id() const override;
1582 
1583  virtual std::unique_ptr<weld::TreeIter> make_iterator(const weld::TreeIter* pOrig
1584  = nullptr) const override;
1585 
1586  virtual void copy_iterator(const weld::TreeIter& rSource, weld::TreeIter& rDest) const override;
1587 
1588  virtual bool get_selected(weld::TreeIter* pIter) const override;
1589 
1590  virtual bool get_cursor(weld::TreeIter* pIter) const override;
1591 
1592  virtual void set_cursor(const weld::TreeIter& rIter) override;
1593 
1594  virtual bool get_iter_first(weld::TreeIter& rIter) const override;
1595 
1596  virtual bool get_iter_abs_pos(weld::TreeIter& rIter, int nPos) const;
1597 
1598  virtual bool iter_next_sibling(weld::TreeIter& rIter) const override;
1599 
1600  virtual bool iter_previous_sibling(weld::TreeIter& rIter) const override;
1601 
1602  virtual bool iter_next(weld::TreeIter& rIter) const override;
1603 
1604  virtual bool iter_previous(weld::TreeIter& rIter) const override;
1605 
1606  virtual bool iter_children(weld::TreeIter& rIter) const override;
1607 
1608  virtual bool iter_parent(weld::TreeIter& rIter) const override;
1609 
1610  virtual void remove(const weld::TreeIter& rIter) override;
1611 
1612  virtual void select(const weld::TreeIter& rIter) override;
1613 
1614  virtual void scroll_to_row(const weld::TreeIter& rIter) override;
1615 
1616  virtual void unselect(const weld::TreeIter& rIter) override;
1617 
1618  virtual int get_iter_depth(const weld::TreeIter& rIter) const override;
1619 
1620  virtual bool iter_has_child(const weld::TreeIter& rIter) const override;
1621 
1622  virtual bool get_row_expanded(const weld::TreeIter& rIter) const override;
1623 
1624  virtual bool get_children_on_demand(const weld::TreeIter& rIter) const override;
1625 
1626  virtual void set_children_on_demand(const weld::TreeIter& rIter,
1627  bool bChildrenOnDemand) override;
1628 
1629  virtual void expand_row(const weld::TreeIter& rIter) override;
1630 
1631  virtual void collapse_row(const weld::TreeIter& rIter) override;
1632 
1633  virtual OUString get_text(const weld::TreeIter& rIter, int col = -1) const override;
1634 
1635  virtual void set_text(const weld::TreeIter& rIter, const OUString& rText,
1636  int col = -1) override;
1637 
1638  virtual OUString get_id(const weld::TreeIter& rIter) const override;
1639 
1640  virtual void set_id(const weld::TreeIter& rIter, const OUString& rId) override;
1641 
1643  sal_uInt8 eDNDConstants) override;
1644 
1645  virtual void set_selection_mode(SelectionMode eMode) override;
1646 
1647  virtual void all_foreach(const std::function<bool(weld::TreeIter&)>& func) override;
1648 
1649  virtual void selected_foreach(const std::function<bool(weld::TreeIter&)>& func) override;
1650 
1651  virtual void visible_foreach(const std::function<bool(weld::TreeIter&)>& func) override;
1652 
1653  virtual void connect_visible_range_changed(const Link<weld::TreeView&, void>& rLink) override;
1654 
1655  virtual void remove_selection() override;
1656 
1657  virtual bool is_selected(const weld::TreeIter& rIter) const override;
1658 
1659  virtual int get_iter_index_in_parent(const weld::TreeIter& rIter) const override;
1660 
1661  virtual int iter_compare(const weld::TreeIter& a, const weld::TreeIter& b) const override;
1662 
1663  virtual void move_subtree(weld::TreeIter& rNode, const weld::TreeIter* pNewParent,
1664  int nIndexInNewParent) override;
1665 
1666  virtual int count_selected_rows() const override;
1667 
1668  virtual int get_height_rows(int nRows) const override;
1669 
1670  virtual void make_sorted() override;
1671 
1672  virtual void set_sort_func(
1673  const std::function<int(const weld::TreeIter&, const weld::TreeIter&)>& func) override;
1674 
1675  virtual void make_unsorted() override;
1676 
1677  virtual void set_sort_order(bool bAscending) override;
1678 
1679  virtual bool get_sort_order() const override;
1680 
1681  virtual void set_sort_indicator(TriState eState, int col) override;
1682 
1683  virtual TriState get_sort_indicator(int col) const override;
1684 
1685  virtual int get_sort_column() const override;
1686 
1687  virtual void set_sort_column(int nColumn) override;
1688 
1690 
1691  virtual bool get_dest_row_at_pos(const Point& rPos, weld::TreeIter* pResult,
1692  bool bDnDMode) override;
1693 
1694  virtual void unset_drag_dest_row() override;
1695 
1696  virtual tools::Rectangle get_row_area(const weld::TreeIter& rIter) const override;
1697 
1698  virtual TreeView* get_drag_source() const override;
1699 
1700  virtual int vadjustment_get_value() const override;
1701 
1702  virtual void vadjustment_set_value(int nValue) override;
1703 
1704  void set_show_expanders(bool bShow) override;
1705 
1706  virtual ~SalInstanceTreeView() override;
1707 };
1708 
1710 {
1711 private:
1713 
1714  DECL_LINK(ExpandedHdl, VclExpander&, void);
1715 
1716 public:
1717  SalInstanceExpander(VclExpander* pExpander, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1718 
1719  virtual void set_label(const OUString& rText) override;
1720 
1721  virtual OUString get_label() const override;
1722 
1723  virtual bool get_expanded() const override;
1724 
1725  virtual void set_expanded(bool bExpand) override;
1726 
1727  virtual bool has_focus() const override;
1728 
1729  virtual void grab_focus() override;
1730 
1731  virtual ~SalInstanceExpander() override;
1732 };
1733 
1735 {
1736 private:
1737  // owner for UserData
1738  std::vector<std::unique_ptr<OUString>> m_aUserData;
1740 
1741  DECL_LINK(SelectHdl, SvTreeListBox*, void);
1742  DECL_LINK(DeSelectHdl, SvTreeListBox*, void);
1743  DECL_LINK(DoubleClickHdl, SvTreeListBox*, bool);
1744  DECL_LINK(CommandHdl, const CommandEvent&, bool);
1745 
1746 public:
1747  SalInstanceIconView(::IconView* pIconView, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1748 
1749  virtual void freeze() override;
1750 
1751  virtual void thaw() override;
1752 
1753  virtual void insert(int pos, const OUString* pStr, const OUString* pId,
1754  const OUString* pIconName, weld::TreeIter* pRet) override;
1755 
1756  virtual void insert(int pos, const OUString* pStr, const OUString* pId,
1757  const VirtualDevice* pIcon, weld::TreeIter* pRet) override;
1758 
1759  virtual OUString get_selected_id() const override;
1760 
1761  virtual OUString get_selected_text() const override;
1762 
1763  virtual int count_selected_items() const override;
1764 
1765  virtual void select(int pos) override;
1766 
1767  virtual void unselect(int pos) override;
1768 
1769  virtual int n_children() const override;
1770 
1771  virtual std::unique_ptr<weld::TreeIter> make_iterator(const weld::TreeIter* pOrig
1772  = nullptr) const override;
1773 
1774  virtual bool get_selected(weld::TreeIter* pIter) const override;
1775 
1776  virtual bool get_cursor(weld::TreeIter* pIter) const override;
1777 
1778  virtual void set_cursor(const weld::TreeIter& rIter) override;
1779 
1780  virtual bool get_iter_first(weld::TreeIter& rIter) const override;
1781 
1782  virtual void scroll_to_item(const weld::TreeIter& rIter) override;
1783 
1784  virtual void selected_foreach(const std::function<bool(weld::TreeIter&)>& func) override;
1785 
1786  virtual OUString get_id(const weld::TreeIter& rIter) const override;
1787 
1788  virtual void clear() override;
1789 
1790  virtual ~SalInstanceIconView() override;
1791 };
1792 
1794 {
1795 private:
1797 
1798  DECL_LINK(ToggleHdl, ::RadioButton&, void);
1799 
1800 public:
1802  bool bTakeOwnership);
1803 
1804  virtual void set_active(bool active) override;
1805 
1806  virtual bool get_active() const override;
1807 
1808  virtual void set_image(VirtualDevice* pDevice) override;
1809 
1810  virtual void set_image(const css::uno::Reference<css::graphic::XGraphic>& rImage) override;
1811 
1812  virtual void set_from_icon_name(const OUString& rIconName) override;
1813 
1814  virtual void set_inconsistent(bool /*inconsistent*/) override;
1815 
1816  virtual bool get_inconsistent() const override;
1817 
1818  virtual void set_label(const OUString& rText) override { SalInstanceButton::set_label(rText); }
1819 
1820  virtual OUString get_label() const override { return SalInstanceButton::get_label(); }
1821 
1822  virtual void set_label_wrap(bool wrap) override { SalInstanceButton::set_label_wrap(wrap); }
1823 
1824  virtual ~SalInstanceRadioButton() override;
1825 };
1826 
1827 class SalInstanceFrame : public SalInstanceContainer, public virtual weld::Frame
1828 {
1829 private:
1831 
1832 public:
1833  SalInstanceFrame(VclFrame* pFrame, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1834 
1835  virtual void set_label(const OUString& rText) override;
1836 
1837  virtual OUString get_label() const override;
1838 
1839  virtual std::unique_ptr<weld::Label> weld_label_widget() const override;
1840 };
1841 
1843 {
1844 protected:
1846  sal_uInt16 m_nLastId;
1847 
1848  DECL_LINK(MenuSelectHdl, ::MenuButton*, void);
1849  DECL_LINK(ActivateHdl, ::MenuButton*, void);
1850 
1851 public:
1852  SalInstanceMenuButton(::MenuButton* pButton, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1853 
1854  virtual void set_active(bool active) override;
1855 
1856  virtual bool get_active() const override;
1857 
1858  virtual void set_inconsistent(bool /*inconsistent*/) override;
1859 
1860  virtual bool get_inconsistent() const override;
1861 
1862  virtual void insert_item(int pos, const OUString& rId, const OUString& rStr,
1863  const OUString* pIconName, VirtualDevice* pImageSurface,
1864  TriState eCheckRadioFalse) override;
1865 
1866  virtual void insert_separator(int pos, const OUString& rId) override;
1867 
1868  virtual void set_item_sensitive(const OString& rIdent, bool bSensitive) override;
1869 
1870  virtual void remove_item(const OString& rId) override;
1871 
1872  virtual void clear() override;
1873 
1874  virtual void set_item_active(const OString& rIdent, bool bActive) override;
1875 
1876  virtual void set_item_label(const OString& rIdent, const OUString& rText) override;
1877 
1878  virtual OUString get_item_label(const OString& rIdent) const override;
1879 
1880  virtual void set_item_visible(const OString& rIdent, bool bShow) override;
1881 
1882  virtual void set_popover(weld::Widget* pPopover) override;
1883 
1884  virtual ~SalInstanceMenuButton() override;
1885 };
1886 
1888 {
1889 private:
1891 
1892  DECL_LINK(PopupModeEndHdl, FloatingWindow*, void);
1893 
1894 public:
1895  SalInstancePopover(DockingWindow* pPopover, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1896 
1898 
1899  virtual void popup_at_rect(weld::Widget* pParent, const tools::Rectangle& rRect) override;
1900 
1901  virtual void popdown() override;
1902 };
1903 
1904 class SalInstanceBox : public SalInstanceContainer, public virtual weld::Box
1905 {
1906 private:
1908 
1909 public:
1910  SalInstanceBox(VclBox* pContainer, SalInstanceBuilder* pBuilder, bool bTakeOwnership);
1911  virtual void reorder_child(weld::Widget* pWidget, int nNewPosition) override;
1912  virtual void sort_native_button_order() override;
1913 };
1914 
1915 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
virtual void set_range(int min, int max) override
virtual void cut_entry_clipboard() override
VclPtr< CheckBox > m_xCheckButton
SalInstanceMenuButton(::MenuButton *pButton, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void insert_vector(const std::vector< weld::ComboBoxEntry > &rItems, bool bKeepExisting) override
Definition: salvtables.hxx:752
virtual std::unique_ptr< weld::SpinButton > weld_spin_button(const OString &id) override
virtual css::uno::Reference< css::datatransfer::dnd::XDropTarget > get_drop_target() override
Definition: salvtables.cxx:555
virtual bool get_direction() const override
Definition: salvtables.cxx:493
virtual void set_can_focus(bool bCanFocus) override
Definition: salvtables.cxx:270
virtual void set_id(int row, const OUString &rId) override
Definition: salvtables.hxx:746
virtual bool get_selected(weld::TreeIter *pIter) const override
virtual void remove_item(const OString &rId) override
virtual std::unique_ptr< weld::TreeIter > make_iterator(const weld::TreeIter *pOrig=nullptr) const override
SalInstanceWidget(vcl::Window *pWidget, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
Definition: salvtables.cxx:249
virtual void set_label(const OUString &rText) override
VclPtr<::Edit > m_xEntry
Definition: salvtables.hxx:551
virtual void set_expanded(bool bExpand) override
virtual bool get_item_sensitive(const OString &rIdent) const override
Definition: salvtables.cxx:870
virtual void select_region(int nStartPos, int nEndPos) override
static void DoRecursivePaint(vcl::Window *pWindow, const Point &rPos, OutputDevice &rOutput)
virtual void set_alignment(TxtAlign eXAlign) override
virtual bool get_modal() const override
virtual void connect_size_allocate(const Link< const Size &, void > &rLink) override
virtual void cut_entry_clipboard() override
virtual std::unique_ptr< weld::Notebook > weld_notebook(const OString &id) override
virtual void clear() override
VclPtr< ToolBox > m_xToolBox
virtual unsigned int get_digits() const override
virtual std::unique_ptr< weld::Toolbar > weld_toolbar(const OString &id) override
virtual void cut_clipboard() override
virtual void set_entry_completion(bool, bool bCaseSensitive=false) override
virtual OUString get_active_text() const override
virtual void scroll_to_row(int pos) override
virtual void HandleEventListener(VclWindowEvent &rEvent)
Definition: salvtables.cxx:599
FieldUnit
virtual void queue_draw_area(int x, int y, int width, int height) override
virtual ~SalInstanceBuilder() override
VclPtr<::Dialog > m_xDialog
Definition: salvtables.hxx:493
virtual int get_margin_start() const override
Definition: salvtables.cxx:379
virtual int get_iter_depth(const weld::TreeIter &rIter) const override
virtual void set_entry_editable(bool bEditable) override
virtual void set_selection_mode(SelectionMode eMode) override
virtual bool has_focus() const override
virtual int get_grid_top_attach() const override
Definition: salvtables.cxx:357
virtual bool iter_children(weld::TreeIter &rIter) const override
virtual void set_image(VirtualDevice *pDevice) override
virtual std::unique_ptr< weld::Container > weld_container(const OString &id) override
virtual bool get_row_expanded(const weld::TreeIter &rIter) const override
virtual void set_sensitive(const OString &rIdent, bool bSensitive)=0
virtual bool is_selected(int pos) const override
virtual void set_editable(bool bEditable) override
SvLBoxButtonData m_aRadioButtonData
virtual void set_item_active(const OString &rIdent, bool bActive) override
virtual OUString get_id(int pos) const override
virtual void set_label_type(weld::LabelType eType) override
virtual Size get_size() const override
virtual void set_image(VirtualDevice *pDevice) override
virtual std::unique_ptr< weld::MenuToggleButton > weld_menu_toggle_button(const OString &id) override
virtual void clear() override
virtual void select_entry_region(int nStartPos, int nEndPos) override
std::map< OString, std::pair< VclPtr< TabPage >, VclPtr< VclGrid > > > m_aAddedPages
virtual Point get_accessible_location_on_screen() override
virtual void set_input_context(const InputContext &rInputContext) override
virtual void thaw() override
virtual void swap(int pos1, int pos2) override
virtual void insert(int pos, const OUString &rStr, const OUString *pId, const OUString *pIconName, VirtualDevice *pImageSurface)=0
virtual std::unique_ptr< weld::Frame > weld_frame(const OString &id) override
virtual void connect_size_allocate(const Link< const Size &, void > &rLink) override
Definition: salvtables.cxx:439
virtual void select_entry_region(int, int) override
virtual void set_entry_message_type(weld::EntryMessageType eType) override
void set_sensitive(SvTreeListEntry *pEntry, bool bSensitive, int col)
virtual void set_active(int pos) override
Definition: salvtables.hxx:726
virtual void set_help_id(const OString &rId) override
Definition: salvtables.cxx:339
SalInstanceBuilder * m_pBuilder
Definition: salvtables.hxx:173
css::uno::Reference< css::accessibility::XAccessibleRelationSet > a11yrelationset
Definition: weld.hxx:50
virtual std::unique_ptr< weld::CheckButton > weld_check_button(const OString &id) override
SalInstanceCheckButton(CheckBox *pButton, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
DECL_LINK(SelectHdl, SvTreeListBox *, void)
virtual int n_children() const override
VclPtr< vcl::Window > m_xWindow
Definition: salvtables.hxx:436
virtual void make_sorted() override
Definition: salvtables.hxx:795
virtual void insert_separator(int pos, const OUString &) override
VclEventId GetId() const
Definition: vclevent.hxx:184
virtual bool get_active() const override
virtual bool get_sensitive() const override
Definition: salvtables.cxx:264
virtual void set_tooltip_text(const OUString &rTip) override
Definition: salvtables.cxx:414
void ensure_mouse_listener()
Definition: salvtables.cxx:224
const tools::Rectangle & GetRect() const
Definition: event.hxx:242
virtual bool iter_parent(weld::TreeIter &rIter) const override
virtual void set_item_ident(int nIndex, const OString &rIdent) override
virtual std::unique_ptr< weld::ToggleButton > weld_toggle_button(const OString &id) override
virtual bool changed_by_direct_pick() const override
A widget used to choose from a list of items and which has no entry.
Definition: lstbox.hxx:82
virtual bool get_sort_order() const override
virtual int iter_compare(const weld::TreeIter &a, const weld::TreeIter &b) const override
bool notify_events_disabled()
Definition: salvtables.cxx:539
virtual Size get_preferred_size() const override
Definition: salvtables.cxx:315
virtual void enable_drag_source(rtl::Reference< TransferDataContainer > &rHelper, sal_uInt8 eDNDConstants) override
const OUString * getEntryData(int index) const
VclPtr<::Button > m_xButton
DECL_LINK(ExpandedHdl, VclExpander &, void)
virtual std::unique_ptr< weld::SizeGroup > create_size_group() override
virtual void insert(int pos, const OUString &rStr, const OUString *pId, const OUString *pIconName, VirtualDevice *pImageSurface) override
VclPtr< vcl_type > m_xComboBox
Definition: salvtables.hxx:669
virtual void insert_separator(int pos, const OUString &rId)=0
virtual std::unique_ptr< weld::Container > weld_parent() const override
virtual void enable_drag_source(rtl::Reference< TransferDataContainer > &rHelper, sal_uInt8 eDNDConstants) override
DECL_LINK(SelectHdl, SvTreeListBox *, void)
virtual std::unique_ptr< weld::MenuButton > weld_menu_button(const OString &id) override
virtual int find_text(const OUString &rStr) const override
Definition: salvtables.hxx:768
virtual int get_value() const override
void set_text_align(SvTreeListEntry *pEntry, double fAlign, int col)
virtual void set_mnemonic_widget(Widget *pTarget) override
virtual bool has_focus() const override
virtual int get_position() const override
void disable_notify_events()
Definition: salvtables.cxx:537
std::vector< ScreenShotEntry > ScreenShotCollection
Definition: weld.hxx:505
virtual int get_max_mru_count() const override
virtual void set_font_color(const Color &rColor) override
virtual void set_modal(bool bModal) override
long Long
std::pair< vcl::RenderContext &, const tools::Rectangle & > target_and_area
css::uno::Reference< css::accessibility::XAccessible > a11yref
Definition: weld.hxx:49
virtual sal_uInt16 get_modifier_state() const override
void call_signal_custom_render(UserDrawEvent *pEvent)
Definition: salvtables.hxx:808
static const AllSettings & GetSettings()
Gets the application's settings.
Definition: svapp.cxx:733
int to_internal_model(int col) const
VclPtr<::MessageDialog > m_xMessageDialog
virtual std::unique_ptr< weld::Scale > weld_scale(const OString &id) override
std::vector< std::unique_ptr< OUString > > m_aUserData
virtual void set_active(bool active) override
virtual std::unique_ptr< weld::Expander > weld_expander(const OString &id) override
virtual void set_active_id(const OUString &rStr) override
Definition: salvtables.hxx:714
SalInstanceComboBoxWithEdit(::ComboBox *pComboBox, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
static void set_font_color(SvTreeListEntry *pEntry, const Color &rColor)
OUString m_sMenuButtonRow
Definition: salvtables.hxx:671
virtual void set_item_sensitive(const OString &rIdent, bool bSensitive) override
virtual void set_item_help_id(const OString &rIdent, const OString &rHelpId) override
Definition: salvtables.cxx:880
virtual OUString strip_mnemonic(const OUString &rLabel) const override
Definition: salvtables.cxx:543
VclPtr< FormattedField > m_xButton
Definition: salvtables.hxx:618
std::function< std::unique_ptr< UIObject >vcl::Window *)> FactoryFunction
virtual void connect_popup_toggled(const Link< ComboBox &, void > &rLink)
Definition: weld.hxx:769
virtual bool get_has_default() const override
Definition: salvtables.cxx:298
virtual bool has_grab() const override
Definition: salvtables.cxx:489
VclPtr< vcl::Window > m_xRefEdit
Definition: salvtables.hxx:496
virtual void HandleMouseEventListener(VclWindowEvent &rEvent) override
virtual OUString get_text() const override
virtual bool get_children_on_demand(const weld::TreeIter &rIter) const override
void set_menu_item_active(const OString &rIdent, bool bActive) override
Definition: salvtables.cxx:901
SalInstanceBox(VclBox *pContainer, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual OUString get_text(int pos) const override
Definition: salvtables.hxx:736
virtual void set_message_type(weld::EntryMessageType eType) override
virtual void set_margin_start(int nMargin) override
Definition: salvtables.cxx:371
SelectionMode
Definition: vclenum.hxx:26
virtual bool get_iter_abs_pos(weld::TreeIter &rIter, int nPos) const
virtual ~SalInstanceWindow() override
virtual void connect_mouse_release(const Link< const MouseEvent &, bool > &rLink) override
Definition: salvtables.cxx:457
VclPtr<::RadioButton > m_xRadioButton
WeldTextFilter m_aTextFilter
Definition: salvtables.hxx:940
virtual void clear()=0
virtual OUString get_item_tooltip_text(const OString &rIdent) const override
bool get_menu_item_active(const OString &rIdent) const override
Definition: salvtables.cxx:936
virtual bool get_overwrite_mode() const override
virtual void set_accessible_description(const OUString &rDescription) override
Definition: salvtables.cxx:388
virtual OString get_help_id() const override
Definition: salvtables.cxx:341
virtual void connect_cursor_position(const Link< TextView &, void > &rLink) override
virtual bool runAsync(std::shared_ptr< weld::DialogController > aOwner, const std::function< void(sal_Int32)> &rEndDialogFn) override
virtual void signal_popup_toggled()
Definition: weld.hxx:696
virtual bool is_active() const override
Definition: salvtables.cxx:289
virtual OString get_page_ident(int nPage) const override
virtual void columns_autosize() override
virtual int get_max_mru_count() const override
virtual bool get_hexpand() const override
Definition: salvtables.cxx:361
virtual ~SalInstanceTreeView() override
virtual void connect_query_tooltip(const Link< const weld::TreeIter &, OUString > &rLink) override
virtual void connect_mouse_press(const Link< const MouseEvent &, bool > &rLink) override
Definition: salvtables.cxx:445
void set_image(SvTreeListEntry *pEntry, const Image &rImage, int col)
virtual ~SalInstanceNotebook() override
virtual std::unique_ptr< weld::Menu > weld_menu(const OString &id) override
virtual void set_mru_entries(const OUString &rEntries) override
virtual bool has_child_focus() const override
Definition: salvtables.cxx:291
virtual void recursively_unset_default_buttons() override
void set_text(SvTreeListEntry *pEntry, const OUString &rText, int col)
virtual void copy_iterator(const weld::TreeIter &rSource, weld::TreeIter &rDest) const override
virtual int vadjustment_get_upper() const override
virtual weld::Button * weld_widget_for_response(int nResponse) override
SystemWindow * getSystemWindow()
Definition: salvtables.cxx:597
WeldTextFilter m_aTextFilter
Definition: salvtables.hxx:557
virtual void set_font(const vcl::Font &rFont) override
virtual ~SalInstanceMenuButton() override
DECL_LINK(MenuSelectHdl,::MenuButton *, void)
SalInstanceEntry(::Edit *pEntry, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
std::unique_ptr< VclBuilder > m_xBuilder
Definition: salvtables.hxx:36
bool HasChildPathFocus(bool bSystemWindow=false) const
Definition: window.cxx:2994
virtual Size get_pixel_size(const OUString &rText) const override
Definition: salvtables.cxx:324
virtual bool HandleKeyEventListener(VclWindowEvent &rEvent)
Definition: salvtables.cxx:669
virtual void thaw() override
virtual void set_accessible_relation_labeled_by(weld::Widget *pLabel) override
Definition: salvtables.cxx:400
virtual void collapse(weld::Widget *pEdit, weld::Widget *pButton) override
virtual void set_sort_order(bool bAscending) override
#define LISTBOX_ENTRY_NOTFOUND
Definition: lstbox.hxx:37
virtual void connect_cursor_position(const Link< Entry &, void > &rLink) override
virtual void sort_native_button_order() override
virtual void vadjustment_set_value(int nValue) override
virtual void connect_mouse_move(const Link< const MouseEvent &, bool > &rLink) override
Definition: salvtables.cxx:451
virtual int get_active() const override
Definition: salvtables.hxx:680
virtual void connect_mnemonic_activate(const Link< Widget &, bool > &rLink) override
Definition: salvtables.cxx:427
virtual bool get_active() const override
virtual void set_grid_left_attach(int nAttach) override
Definition: salvtables.cxx:343
virtual void set_item_popover(const OString &rIdent, weld::Widget *pPopover) override
Definition: salvtables.cxx:959
virtual bool HandleKeyEventListener(VclWindowEvent &) override
virtual int get_height_rows(int nRows) const override
VclPtr< VclFrame > m_xFrame
virtual bool iter_next_sibling(weld::TreeIter &rIter) const override
o3tl::sorted_vector< int > m_aCustomRenders
virtual void undo_collapse() override
virtual OUString get_mru_entries() const override
static OutputDevice * GetDefaultDevice()
Get the default "device" (in this case the default window).
Definition: svapp.cxx:1069
virtual void help_hierarchy_foreach(const std::function< bool(const OString &)> &func) override
std::pair< SvTreeListEntry *, OUString > IterString
bool get_text_emphasis(SvTreeListEntry *pEntry, int col) const
const bool m_bTakeOwnership
Definition: salvtables.hxx:183
virtual bool has_focus() const override
Definition: salvtables.hxx:695
WinBits const WB_NOPOINTERFOCUS
virtual void set_grid_width(int nCols) override
Definition: salvtables.cxx:350
virtual void set_item_menu(const OString &rIdent, weld::Menu *pMenu) override
Definition: salvtables.hxx:835
VclPtr< VclBox > m_xBox
virtual vcl::Font get_entry_font() override
virtual void connect_focus_in(const Link< Widget &, void > &rLink) override
Definition: salvtables.cxx:421
virtual bool get_sensitive(const OString &rIdent) const =0
bool get_selection_bounds(int &rStartPos, int &rEndPos) override
virtual void set_accessible_relation_label_for(weld::Widget *pLabeled) override
Definition: salvtables.cxx:407
DECL_LINK(HelpHdl, vcl::Window &, bool)
SalInstanceTreeView(SvTabListBox *pTreeView, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void set_item_image(const OString &rIdent, const css::uno::Reference< css::graphic::XGraphic > &rIcon) override
virtual bool get_selected(weld::TreeIter *pIter) const override
o3tl::sorted_vector< SvTreeListEntry * > m_aExpandingPlaceHolderParents
virtual void set_position(int nCursorPos) override
virtual std::unique_ptr< weld::Entry > weld_entry(const OString &id) override
virtual std::unique_ptr< weld::Image > weld_image(const OString &id) override
virtual void connect_focus_out(const Link< Widget &, void > &rLink) override
Definition: salvtables.cxx:433
virtual bool iter_previous(weld::TreeIter &rIter) const override
EntryMessageType
Definition: weld.hxx:666
virtual void vadjustment_set_value(int value) override
virtual std::unique_ptr< weld::Spinner > weld_spinner(const OString &id) override
Link< ScrollBar *, void > m_aOrigVScrollHdl
SalInstanceExpander(VclExpander *pExpander, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual int get_margin_end() const override
Definition: salvtables.cxx:381
virtual void enable_toggle_buttons(weld::ColumnToggleType eType) override
virtual void set_max_length(int nChars) override
std::pair< vcl::RenderContext &, const SvTreeListEntry & > svtree_measure_args
virtual int find_id(const OUString &rStr) const override
Definition: salvtables.hxx:776
double toField(int nValue) const
virtual void set_item_menu(const OString &rIdent, weld::Menu *pMenu) override
Definition: salvtables.cxx:980
virtual void scroll_to_item(const weld::TreeIter &rIter) override
sal_uInt16 m_nLastId
Definition: salvtables.hxx:142
size_t pos
SalInstancePopover(DockingWindow *pPopover, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual OString get_buildable_name() const override
Definition: salvtables.cxx:332
int get_menu_button_width() const override
Definition: salvtables.hxx:850
virtual std::unique_ptr< weld::DrawingArea > weld_drawing_area(const OString &id, const a11yref &rA11yImpl=nullptr, FactoryFunction pUITestFactoryFunction=nullptr, void *pUserData=nullptr) override
virtual void freeze() override
virtual void connect_container_focus_changed(const Link< Container &, void > &rLink) override
virtual vcl::Font get_entry_font() override
virtual int get_n_pages() const override
virtual void set_label(const OString &rIdent, const OUString &rLabel)=0
virtual void set_max_mru_count(int nCount) override
virtual void set_direction(bool bRTL) override
Definition: salvtables.cxx:495
virtual int count_selected_rows() const override
SalInstanceToolbar(ToolBox *pToolBox, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
Definition: salvtables.cxx:856
SalInstanceDialog(::Dialog *pDialog, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
LabelType
Definition: weld.hxx:2075
virtual void HandleEventListener(VclWindowEvent &rEvent) override
virtual int vadjustment_get_page_size() const override
virtual void set_secondary_text(const OUString &rText) override
virtual int get_margin_bottom() const override
Definition: salvtables.cxx:377
virtual bool get_active() const override
void set_toggle(SvTreeListEntry *pEntry, TriState eState, int col)
virtual int find_id(const OUString &rId) const override
virtual tools::Rectangle get_monitor_workarea() const override
constexpr tools::Long GetWidth() const
virtual void queue_resize() override
Definition: salvtables.cxx:519
WindowStateMask
Definition: vclenum.hxx:121
virtual ~SalInstanceToolbar() override
std::map< ToolBoxItemId, VclPtr< PopupMenu > > m_aMenus
DECL_LINK(UpDownHdl, SpinField &, void)
void CallHandleEventListener(VclWindowEvent &rEvent)
Definition: salvtables.hxx:856
virtual void freeze() override
void set_show_expanders(bool bShow) override
virtual OUString get_accessible_description() const override
Definition: salvtables.cxx:395
virtual void move_subtree(weld::TreeIter &rNode, const weld::TreeIter *pNewParent, int nIndexInNewParent) override
virtual void make_unsorted() override
std::vector< VclPtr< vcl::Window > > m_aHiddenWidgets
Definition: salvtables.hxx:497
virtual void popup_at_rect(weld::Widget *pParent, const tools::Rectangle &rRect) override
virtual int get_page_index(const OString &rIdent) const override
virtual void set_sort_indicator(TriState eState, int col) override
virtual TriState get_sort_indicator(int col) const override
SalInstanceComboBoxWithoutEdit(ListBox *pListBox, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void copy_entry_clipboard() override
virtual void set_entry_editable(bool bEditable) override
virtual void start_editing(const weld::TreeIter &rIter) override
Definition: edit.hxx:55
virtual void HandleEventListener(VclWindowEvent &rEvent) override
virtual void set_margin_top(int nMargin) override
Definition: salvtables.cxx:367
virtual void replace_selection(const OUString &rText) override
virtual ~SalInstanceTextView() override
void override_child_help(vcl::Window *pParent)
virtual bool has_focus() const override
virtual void connect_visible_range_changed(const Link< weld::TreeView &, void > &rLink) override
virtual int get_column_width(int nColumn) const override
virtual void set_label(const OUString &rText) override
virtual void grab_add() override
Definition: salvtables.cxx:487
virtual void reorder_child(weld::Widget *pWidget, int nNewPosition) override
virtual bool iter_previous_sibling(weld::TreeIter &rIter) const override
virtual void selected_foreach(const std::function< bool(weld::TreeIter &)> &func) override
virtual void set_icon_size(vcl::ImageType eType) override
virtual void connect_popup_toggled(const Link< ComboBox &, void > &rLink) override
Definition: salvtables.hxx:802
virtual void insert(const weld::TreeIter *pParent, int pos, const OUString *pStr, const OUString *pId, const OUString *pIconName, VirtualDevice *pImageSurface, bool bChildrenOnDemand, weld::TreeIter *pRet) override
virtual std::unique_ptr< weld::Dialog > weld_dialog(const OString &id) override
virtual void select(int pos) override
virtual OUString get_column_title(int nColumn) const override
virtual int get_drop_index(const Point &rPoint) const override
virtual void set_inconsistent(bool) override
virtual std::vector< int > get_selected_rows() const override
virtual bool get_entry_selection_bounds(int &rStartPos, int &rEndPos) override
SalInstanceRadioButton(::RadioButton *pButton, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual OUString get_active_text() const override
virtual void freeze() override
Definition: salvtables.cxx:497
virtual void set_entry_width_chars(int nChars) override
virtual int get_text_height() const override
Definition: salvtables.cxx:322
virtual void set_text(const OUString &rText) override
SalInstanceMessageDialog(::MessageDialog *pDialog, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void replace_selection(const OUString &rText) override
virtual void insert_item(int pos, const OUString &rId) override
Definition: salvtables.cxx:991
virtual void get_increments(int &step, int &page) const override
DECL_LINK(PopupScreenShotMenuHdl, const CommandEvent &, bool)
virtual bool get_modal() const override
virtual void queue_draw() override
virtual VclPtr< VirtualDevice > create_virtual_device() const override
Definition: salvtables.cxx:548
virtual OUString get_tooltip_text() const override
Definition: salvtables.cxx:419
void InvalidateModelEntry(SvTreeListEntry *pEntry)
virtual css::uno::Reference< css::datatransfer::clipboard::XClipboard > get_clipboard() const override
Definition: salvtables.cxx:561
virtual void paste_entry_clipboard() override
SalInstanceFrame(VclFrame *pFrame, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void set_tab_label_text(const OString &rIdent, const OUString &rText) override
VclPtr< TabControl > m_xNotebook
virtual ~SalInstanceEntry() override
virtual VclPtr< VirtualDevice > screenshot() override
SalInstanceNotebook(TabControl *pNotebook, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void insert_separator(int pos, const OUString &) override
virtual OString get_id(int pos) const =0
virtual void set_inconsistent(bool inconsistent) override
void clear()
Definition: vclptr.hxx:190
VclPtr< VclMultiLineEdit > m_xTextView
virtual void collapse_row(const weld::TreeIter &rIter) override
virtual void set_visible(const OString &rIdent, bool bVisible)=0
PopupMenu * getMenu() const
Definition: salvtables.cxx:834
virtual weld::Container * weld_content_area() override
virtual std::unique_ptr< weld::Label > weld_label_widget() const override
virtual float get_approximate_digit_width() const override
Definition: salvtables.cxx:317
DECL_LINK(ChangeHdl, Edit &, void)
virtual void paste_clipboard() override
VclPtr<::MenuButton > m_xMenuButton
virtual void hide() override
Definition: salvtables.cxx:302
virtual bool can_move_cursor_with_up() const override
vcl::RenderContext * GetRenderContext() const
Definition: event.hxx:241
virtual std::unique_ptr< weld::ProgressBar > weld_progress_bar(const OString &id) override
virtual void present() override
SalInstanceDrawingArea(VclDrawingArea *pDrawingArea, SalInstanceBuilder *pBuilder, const a11yref &rAlly, FactoryFunction pUITestFactoryFunction, void *pUserData, bool bTakeOwnership)
virtual std::unique_ptr< weld::IconView > weld_icon_view(const OString &id) override
virtual void set_clicks_to_toggle(int nToggleBehavior) override
virtual OUString get_selected_id() const override
int i
virtual void set_popover(weld::Widget *pPopover) override
SalInstanceContainer(vcl::Window *pContainer, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual Point get_pointer_position() const override
virtual int get_count() const override
Definition: salvtables.hxx:766
virtual void add_button(const OUString &rText, int nResponse, const OString &rHelpId=OString()) override
virtual void set_highlight_background() override
Definition: salvtables.cxx:592
void ensure_key_listener()
Definition: salvtables.cxx:213
virtual void bulk_insert_for_each(int nSourceCount, const std::function< void(weld::TreeIter &, int nSourceIndex)> &func, const weld::TreeIter *pParent=nullptr, const std::vector< int > *pFixedWidths=nullptr) override
ImageType
Definition: vclenum.hxx:324
virtual void connect_key_release(const Link< const KeyEvent &, bool > &rLink) override
Definition: salvtables.cxx:469
virtual void child_grab_focus() override
virtual ~SalInstanceSpinButton() override
DECL_LINK(EventListener, VclWindowEvent &, void)
virtual void select_region(int nStartPos, int nEndPos) override
virtual OUString get_item_label(const OString &rIdent) const override
virtual int n_children() const =0
std::map< ToolBoxItemId, VclPtr< vcl::Window > > m_aFloats
virtual OUString get_label() const override
virtual void paste_clipboard() override
virtual void set_from_icon_name(const OUString &rIconName) override
virtual bool get_popup_shown() const override
Definition: salvtables.hxx:800
virtual OUString get_label() const override
virtual void set_title_background() override
Definition: salvtables.cxx:581
virtual int vadjustment_get_value() const override
virtual void end_editing() override
virtual bool get_active(const OString &rIdent) const =0
virtual bool get_iter_first(weld::TreeIter &rIter) const override
virtual void remove_page(const OString &rIdent) override
virtual void set_extra_row_indent(const weld::TreeIter &rIter, int nIndentLevel) override
virtual bool get_resizable() const override
DECL_LINK(ToggleHdl,::RadioButton &, void)
virtual bool get_editable() const override
virtual void set_item_sensitive(const OString &rIdent, bool bSensitive) override
Definition: salvtables.cxx:865
virtual std::unique_ptr< weld::FormattedSpinButton > weld_formatted_spin_button(const OString &id) override
virtual int vadjustment_get_value() const override
virtual void insert_separator(int pos, const OUString &) override
virtual void set_column_editables(const std::vector< bool > &rEditables) override
virtual void set_digits(unsigned int digits) override
DECL_LINK(ToggleHdl, CheckBox &, void)
bool IsFirstFreeze() const
Definition: salvtables.hxx:202
SalInstanceTreeIter(SvTreeListEntry *pIter)
virtual bool changed_by_direct_pick() const override
virtual ~SalInstanceComboBoxWithoutEdit() override
virtual void set_size_request(int nWidth, int nHeight) override
Definition: salvtables.cxx:304
Some things multiple-inherit from VclAbstractDialog and OutputDevice, so we need to use virtual inher...
Definition: outdev.hxx:168
virtual void im_context_set_cursor_location(const tools::Rectangle &rCursorRect, int nExtTextInputWidth) override
SalInstanceBuilder(vcl::Window *pParent, const OUString &rUIRoot, const OUString &rUIFile, const css::uno::Reference< css::frame::XFrame > &rFrame=css::uno::Reference< css::frame::XFrame >())
virtual void set_active(const OString &rIdent, bool bActive)=0
virtual bool get_entry_selection_bounds(int &, int &) override
void AddStringItem(SvTreeListEntry *pEntry, const OUString &rStr, int nCol)
VclPtr< VclDrawingArea > m_xDrawingArea
virtual void set_max_mru_count(int) override
virtual void grab_remove() override
Definition: salvtables.cxx:491
virtual OUString get_label() const override
virtual std::unique_ptr< weld::Widget > weld_widget(const OString &id) override
virtual ~SalInstanceButton() override
virtual void set_entry_message_type(weld::EntryMessageType) override
virtual void set_value(int value) override
virtual std::unique_ptr< weld::ScrolledWindow > weld_scrolled_window(const OString &id, bool bUserManagedScrolling=false) override
virtual bool has_focus() const override
Definition: salvtables.cxx:287
constexpr tools::Long Top() const
virtual std::unique_ptr< weld::TextView > weld_text_view(const OString &id) override
std::vector< std::unique_ptr< OUString > > m_aUserData
SalInstanceButton(::Button *pButton, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void set_window_state(const OString &rStr) override
virtual void set_background(const Color &rColor) override
Definition: salvtables.cxx:233
virtual a11yrelationset get_accessible_relation_set() override
virtual OUString get_item_label(const OString &rIdent) const override
virtual void connect_key_press(const Link< const KeyEvent &, bool > &rLink) override
Definition: salvtables.cxx:463
virtual void set_width_chars(int nChars) override
virtual void visible_foreach(const std::function< bool(weld::TreeIter &)> &func) override
virtual void popdown() override
VclPtr< Control > m_xLabel
Definition: salvtables.hxx:396
virtual void set_margin_bottom(int nMargin) override
Definition: salvtables.cxx:369
VclPtr<::IconView > m_xIconView
virtual void all_foreach(const std::function< bool(weld::TreeIter &)> &func) override
VclPtr< vcl::Window > m_xWidget
Definition: salvtables.hxx:172
tools::Long m_nOldEditWidthReq
Definition: salvtables.hxx:498
WinBits const WB_SORT
virtual void clear() override
virtual bool get_cursor(weld::TreeIter *pIter) const override
virtual ~SalInstanceCheckButton() override
virtual void set_hexpand(bool bExpand) override
Definition: salvtables.cxx:359
virtual void set_item_label(const OString &rIdent, const OUString &rText) override
virtual void connect_key_press(const Link< const KeyEvent &, bool > &rLink) override
virtual int get_n_items() const override
DECL_LINK(ChangeHdl, Edit &, void)
virtual void set_column_title(int nColumn, const OUString &rTitle) override
virtual bool get_editable() const override
virtual void set_title(const OUString &rTitle) override
virtual int get_width_chars() const override
void do_insert(const weld::TreeIter *pParent, int pos, const OUString *pStr, const OUString *pId, const OUString *pIconName, const VirtualDevice *pImageSurface, bool bChildrenOnDemand, weld::TreeIter *pRet, bool bIsSeparator)
virtual OUString get_label() const override
virtual OUString get_title() const override
virtual void set_custom_button(VirtualDevice *pDevice) override
virtual void insert(int pos, const OUString &rId, const OUString &rStr, const OUString *pIconName, VirtualDevice *pImageSurface, const css::uno::Reference< css::graphic::XGraphic > &rImage, TriState eCheckRadioFalse)=0
virtual std::unique_ptr< weld::MessageDialog > weld_message_dialog(const OString &id) override
virtual void remove_selection() override
virtual OUString get_label() const override
virtual void set_max_length(int nChars) override
virtual int get_grid_left_attach() const override
Definition: salvtables.cxx:348
const OUString * getEntryData(int index) const
Definition: salvtables.hxx:688
virtual void set_label(const OUString &rText) override
DECL_LINK(PaintHdl, target_and_area, void)
virtual void selected_foreach(const std::function< bool(weld::TreeIter &)> &func) override
virtual bool iter_has_child(const weld::TreeIter &rIter) const override
virtual void set_item_active(const OString &rIdent, bool bActive) override
Definition: salvtables.cxx:890
void set_text_emphasis(SvTreeListEntry *pEntry, bool bOn, int col=-1)
float GetDPIScaleFactor() const
Definition: outdev.hxx:393
virtual void unselect(int pos) override
virtual ~SalInstanceWidget() override
Definition: salvtables.cxx:521
sal_uInt16 GetItemId() const
Definition: event.hxx:243
virtual void set_item_tooltip_text(int nIndex, const OUString &rTip) override
virtual void clear() override
Definition: salvtables.hxx:789
virtual std::unique_ptr< weld::ComboBox > weld_combo_box(const OString &id) override
virtual void set_text(const OUString &rText) override
ColumnToggleType
Definition: weld.hxx:829
virtual std::unique_ptr< weld::Assistant > weld_assistant(const OString &id) override
virtual void set_entry_text(const OUString &) override
virtual bool iter_next(weld::TreeIter &rIter) const override
virtual void set_sort_column(int nColumn) override
void set_header_item_width(const std::vector< int > &rWidths)
virtual void unset_drag_dest_row() override
virtual void set_font_color(const Color &rColor) override
virtual int vadjustment_get_lower() const override
virtual void set_sort_func(const std::function< int(const weld::TreeIter &, const weld::TreeIter &)> &func) override
void clear_child_help(vcl::Window *pParent)
virtual void set_font(const vcl::Font &rFont) override
virtual void set_placeholder_text(const OUString &rText) override
void signal_custom_render(vcl::RenderContext &rDevice, const tools::Rectangle &rRect, bool bSelected, const OUString &rId)
Definition: weld.hxx:699
virtual void set_busy_cursor(bool bBusy) override
Definition: salvtables.cxx:511
SalInstanceWindow(vcl::Window *pWindow, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual int get_cursor_index() const override
static TriState do_get_toggle(SvTreeListEntry *pEntry, int col)
virtual bool get_extents_relative_to(const Widget &rRelative, int &x, int &y, int &width, int &height) const override
Definition: salvtables.cxx:475
void enable_notify_events()
Definition: salvtables.cxx:541
virtual void click(const Point &rPos) override
virtual bool get_vexpand() const override
Definition: salvtables.cxx:365
virtual SystemEnvData get_system_data() const override
virtual OUString get_active_id() const override
Definition: salvtables.hxx:701
virtual void set_children_on_demand(const weld::TreeIter &rIter, bool bChildrenOnDemand) override
virtual int iter_n_children(const weld::TreeIter &rIter) const override
virtual css::uno::Reference< css::awt::XWindow > CreateChildFrame() override
virtual void set_buildable_name(const OString &rId) override
Definition: salvtables.cxx:334
virtual tools::Rectangle get_row_area(const weld::TreeIter &rIter) const override
VclPtr< PopupMenu > m_xMenu
Definition: salvtables.hxx:139
virtual void HandleEventListener(VclWindowEvent &rEvent) override
Definition: menu.hxx:123
virtual ~SalInstanceRadioButton() override
virtual void set_default_response(int nResponse) override
virtual int get_margin_top() const override
Definition: salvtables.cxx:375
A widget used to choose from a list of items.
Definition: weld.hxx:676
std::vector< std::shared_ptr< OUString > > m_aUserData
Definition: salvtables.hxx:668
virtual void set_font_color(const Color &rColor) override
virtual bool get_item_active(const OString &rIdent) const override
Definition: salvtables.cxx:896
virtual TreeView * get_drag_source() const override
virtual OUString filter(const OUString &rText) override
virtual OUString get_secondary_text() const override
SalInstanceIconView(::IconView *pIconView, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
DECL_LINK(PopupModeEndHdl, FloatingWindow *, void)
SvTabListBox & getTreeView()
virtual OString popup_at_rect(weld::Widget *pParent, const tools::Rectangle &rRect)=0
virtual void move(weld::Widget *pWidget, weld::Container *pNewParent) override
virtual std::unique_ptr< weld::MetricSpinButton > weld_metric_spin_button(const OString &id, FieldUnit eUnit) override
Link< OUString &, bool > & m_rInsertTextHdl
Definition: salvtables.hxx:540
Definition: ctrl.hxx:81
VclPtr< VirtualDevice > create_render_virtual_device() const override
Definition: salvtables.hxx:828
virtual bool has_entry() const override
virtual bool get_dest_row_at_pos(const Point &rPos, weld::TreeIter *pResult, bool bDnDMode) override
virtual void set_label_wrap(bool wrap) override
virtual std::unique_ptr< weld::Calendar > weld_calendar(const OString &id) override
virtual void set_inconsistent(bool) override
virtual void set_stack_background() override
Definition: salvtables.cxx:576
virtual OUString get_label(const OString &rIdent) const =0
virtual int n_children() const override
virtual void window_move(int x, int y) override
unsigned char sal_uInt8
void fire_signal_changed()
virtual void set_entry_completion(bool bEnable, bool bCaseSensitive=false) override
virtual void show() override
virtual void connect_get_property_tree(const Link< tools::JsonWriter &, void > &rLink) override
Definition: salvtables.cxx:566
virtual weld::Container * get_page(const OString &rIdent) const override
void do_set_toggle(SvTreeListEntry *pEntry, TriState eState, int col)
virtual OString get_current_page_ident() const override
virtual OString get_item_ident(int nIndex) const override
virtual std::unique_ptr< weld::EntryTreeView > weld_entry_tree_view(const OString &containerid, const OString &entryid, const OString &treeviewid) override
virtual OUString get_id(const weld::TreeIter &rIter) const override
virtual void draw(OutputDevice &rOutput, const Point &rPos, const Size &rSizePixel) override
virtual int get_iter_index_in_parent(const weld::TreeIter &rIter) const override
DECL_LINK(ClickHdl, ToolBox *, void)
virtual OutputDevice & get_ref_device() override
virtual void set_sensitive(bool sensitive) override
Definition: salvtables.cxx:262
virtual void set_custom_renderer(bool bOn) override
DECL_LINK(SelectHdl, ListBox &, void)
virtual void set_entry_placeholder_text(const OUString &) override
virtual void set_accessible_name(const OUString &rName) override
Definition: salvtables.cxx:383
sal_Int32 m_nOldBorderWidth
Definition: salvtables.hxx:499
virtual OUString get_selected_id() const override
virtual int get_selected_index() const override
virtual void set_active(bool active) override
Definition: image.hxx:39
virtual int run() override
static VclPtr< reference_type > Create(Arg &&...arg)
A construction helper for VclPtr.
Definition: vclptr.hxx:127
std::tuple< vcl::RenderContext &, const tools::Rectangle &, const SvTreeListEntry & > svtree_render_args
virtual ~SalInstanceDrawingArea() override
virtual void set_increments(int step, int) override
virtual void set_active(bool active) override
virtual void set_mru_entries(const OUString &) override
virtual void insert(int pos, const OUString *pStr, const OUString *pId, const OUString *pIconName, weld::TreeIter *pRet) override
virtual void set_overwrite_mode(bool bOn) override
virtual bool has_toplevel_focus() const override
virtual OUString get_text() const override
TxtAlign
Definition: vclenum.hxx:360
virtual int count_selected_items() const override
int fromField(double fValue) const
virtual OUString get_selected_text() const override
SvTreeListEntry * GetPlaceHolderChild(SvTreeListEntry *pEntry) const
DECL_LINK(DeactivatePageHdl, TabControl *, bool)
bool IsDummyEntry(SvTreeListEntry *pEntry) const
virtual void get_range(int &min, int &max) const override
VclPtr< vcl::Window > m_xContainer
Definition: salvtables.hxx:417
virtual bool has_entry() const override
virtual void copy_clipboard() override
virtual void set_custom_renderer(bool bOn) override
OUString get_text(SvTreeListEntry *pEntry, int col) const
virtual void set_from_icon_name(const OUString &rIconName) override
virtual void expand_row(const weld::TreeIter &rIter) override
virtual vcl::Font get_font() override
Definition: salvtables.cxx:330
virtual void set_primary_text(const OUString &rText) override
virtual vcl::ImageType get_icon_size() const override
virtual bool get_visible() const override
Definition: salvtables.cxx:266
virtual void insert(int pos, const OUString &rStr, const OUString *pId, const OUString *pIconName, VirtualDevice *pImageSurface) override
SvLBoxButtonData m_aCheckButtonData
PointerStyle
Definition: ptrstyle.hxx:25
const tools::Long nButtonWidth
virtual void SetInstallLOKNotifierHdl(const Link< void *, vcl::ILibreOfficeKitNotifier * > &rLink) override
virtual void set_item_visible(const OString &rIdent, bool bShow) override
virtual OUString get_selected_text() const override
virtual void set_margin_end(int nMargin) override
Definition: salvtables.cxx:373
SalInstanceComboBox(vcl_type *pComboBox, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
Definition: salvtables.hxx:674
virtual OUString get_primary_text() const override
virtual ~SalInstanceExpander() override
TriState get_toggle(SvTreeListEntry *pEntry, int col) const
virtual void unselect(int pos) override
virtual void copy_clipboard() override
virtual void make_sorted() override
virtual bool get_inconsistent() const override
virtual bool get_item_visible(const OString &rIdent) const override
Definition: salvtables.cxx:885
A widget used to choose from a list of items and which has an entry.
Definition: combobox.hxx:38
virtual std::unique_ptr< weld::TreeView > weld_tree_view(const OString &id) override
virtual void set_modal(bool bModal) override
virtual OUString get_tab_label_text(const OString &rIdent) const override
Event to pass information for UserDraw() handling eg. in comboboxes.
Definition: event.hxx:221
VclPtr< SvTabListBox > m_xTreeView
virtual void HandleMouseEventListener(VclWindowEvent &rEvent)
Definition: salvtables.cxx:620
virtual void set_cursor(PointerStyle ePointerStyle) override
virtual void set_item_icon_name(const OString &rIdent, const OUString &rIconName) override
virtual bool equal(const TreeIter &rOther) const override
void update_checkbutton_column_width(SvTreeListEntry *pEntry)
virtual void set_grid_top_attach(int nAttach) override
Definition: salvtables.cxx:352
virtual OUString get_accessible_name() const override
Definition: salvtables.cxx:393
virtual bool get_inconsistent() const override
virtual a11yref get_accessible_parent() override
bool get_selection_bounds(int &rStartPos, int &rEndPos) override
SalInstanceLabel(Control *pLabel, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual weld::ScreenShotCollection collect_screenshot_data() override
virtual void set_has_default(bool has_default) override
Definition: salvtables.cxx:293
virtual void set_entry_text(const OUString &rText) override
virtual void set_vexpand(bool bExpand) override
Definition: salvtables.cxx:363
virtual void set_entry_max_length(int) override
virtual void set_cursor(const weld::TreeIter &rIter) override
SalInstanceSpinButton(FormattedField *pButton, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
virtual void hide() override
OString get_current_page_help_id() const
virtual void set_column_fixed_widths(const std::vector< int > &rWidths) override
virtual css::uno::Reference< css::awt::XWindow > GetXWindow() override
virtual void insert_separator(int pos, const OUString &) override
Definition: salvtables.cxx:998
bool IsSelected() const
Definition: event.hxx:244
VclPtr< vcl::Window > m_aOwnedToplevel
Definition: salvtables.hxx:37
DECL_LINK(ClickHdl,::Button *, void)
virtual std::unique_ptr< weld::Button > weld_button(const OString &id) override
virtual OUString get_label() const override
virtual void grab_focus() override
DECL_STATIC_LINK(SalInstanceTreeView, FinishDragHdl, SvTreeListBox *, void)
virtual std::unique_ptr< weld::Label > weld_label(const OString &id) override
virtual bool get_iter_first(weld::TreeIter &rIter) const override
SalInstanceTreeIter(const SalInstanceTreeIter *pOrig)
virtual std::unique_ptr< weld::TreeIter > make_iterator(const weld::TreeIter *pOrig=nullptr) const override
virtual void set_label_wrap(bool wrap) override
virtual void set_entry_font(const vcl::Font &) override
virtual void thaw() override
Definition: salvtables.cxx:504
virtual void grab_focus() override
Definition: salvtables.cxx:280
virtual void get_property_tree(tools::JsonWriter &rJsonWriter) override
Definition: salvtables.cxx:571
Link<::Button *, void > const m_aOldClickHdl
WinBits const WB_FLATBUTTON
virtual void show() override
Definition: salvtables.cxx:300
virtual OUString get_mru_entries() const override
virtual void set_entry_max_length(int nChars) override
virtual void insert_item(int pos, const OUString &rId, const OUString &rStr, const OUString *pIconName, VirtualDevice *pImageSurface, TriState eCheckRadioFalse) override
virtual std::unique_ptr< weld::RadioButton > weld_radio_button(const OString &id) override
virtual void copy_entry_clipboard() override
virtual void set_label(const OUString &rText) override
virtual void set_monospace(bool bMonospace) override
std::vector< std::shared_ptr< SalInstanceContainer > > m_aPages
virtual void set_centered_on_parent(bool) override
TriState
virtual ~SalInstanceComboBoxWithEdit() override
virtual Point get_position() const override
virtual void set_toolbar_background() override
Definition: salvtables.cxx:586
WeldTextFilter(Link< OUString &, bool > &rInsertTextHdl)
void implResetDefault(const vcl::Window *_pWindow)
virtual void set_entry_placeholder_text(const OUString &rText) override
virtual void set_alignment(TxtAlign eXAlign) override
virtual void HandleEventListener(VclWindowEvent &rEvent) override
virtual void set_label(const OUString &rText) override
void set_label_wrap(bool bWrap)
virtual void set_entry_font(const vcl::Font &rFont) override
virtual OUString get_id(int pos) const override
Definition: salvtables.hxx:738
virtual bool get_expanded() const override
virtual void cut_clipboard() override
virtual void queue_draw() override
virtual std::unique_ptr< weld::Paned > weld_paned(const OString &id) override
virtual ~SalInstanceIconView() override
virtual int get_current_page() const override
SvTreeListEntry * iter
virtual void set_current_page(int nPage) override
virtual void connect_key_release(const Link< const KeyEvent &, bool > &rLink) override
int to_external_model(int col) const
virtual std::unique_ptr< weld::Popover > weld_popover(const OString &id) override
virtual void set_entry_width_chars(int) override
virtual Size get_size_request() const override
Definition: salvtables.cxx:310
virtual void insert_page(const OString &rIdent, const OUString &rLabel, int nPos) override
virtual bool get_cursor(weld::TreeIter *pIter) const override
DECL_LINK(ChangeHdl, Edit &, void)
ScopedVclPtr< MenuButton > m_xMenuButton
Definition: salvtables.hxx:670
Formatter & m_rFormatter
Definition: salvtables.hxx:619
virtual void set_centered_column(int nCol) override
virtual std::unique_ptr< weld::LinkButton > weld_link_button(const OString &id) override
virtual void response(int nResponse) override
virtual bool can_move_cursor_with_down() const override
virtual void set_column_custom_renderer(int nColumn, bool bEnable) override
VclPtr< DockingWindow > m_xPopover
virtual void resize_to_request() override
virtual bool is_visible() const override
Definition: salvtables.cxx:268
bool IsLastThaw() const
Definition: salvtables.hxx:203
SalInstanceTextView(VclMultiLineEdit *pTextView, SalInstanceBuilder *pBuilder, bool bTakeOwnership)
VclPtr< VclExpander > m_xExpander
sal_uInt16 nPos
virtual void set_label(const OUString &rText) override
virtual void insert_separator(int pos, const OUString &rId) override
void set_id(SvTreeListEntry *pEntry, const OUString &rId)
virtual void set_font(const vcl::Font &rFont) override
virtual weld::Container * weld_message_area() override
void ensure_event_listener()
Definition: salvtables.cxx:201
virtual void set_editable(bool bEditable) override
virtual int find_text(const OUString &rText) const override
virtual void set_cursor(int pos) override
vcl::Window * getWidget() const
Definition: salvtables.cxx:535
virtual OString get_window_state(WindowStateMask nMask) const override
virtual bool get_inconsistent() const override
virtual void set_item_visible(const OString &rIdent, bool bVisible) override
Definition: salvtables.cxx:875
virtual void connect_editing(const Link< const weld::TreeIter &, bool > &rStartLink, const Link< const iter_string &, bool > &rEndLink) override
constexpr tools::Long GetHeight() const
virtual void set_item_label(int nIndex, const OUString &rLabel) override
virtual std::unique_ptr< weld::Box > weld_box(const OString &id) override
virtual int get_sort_column() const override
virtual void select(int pos) override
OUString sId
virtual void paste_entry_clipboard() override
virtual std::unique_ptr< weld::Window > create_screenshot_window() override