wxPreviewControlBar(3erl)

πŸ’… wxPreviewControlBar (3erl) β€” Erlang Module Definition

okay bestie, so this is the Erlang module definition page for wxPreviewControlBar, straight out of the wx docs (the Erlang binding of wxWidgets 2.2.2.1, iykyk) πŸŽ€


✨ NAME ✨

wxPreviewControlBar β€” literally just the Functions for the wxPreviewControlBar class. that's the whole vibe πŸ¦‹


🌸 DESCRIPTION 🌸

This is the default implementation of the preview control bar, bestie β€” think a panel with buttons and a zoom control. that's it, that's the whole thing πŸ’…

You can totally derive a new class from this and override some or all of its member functions to change the behaviour and appearance; or you can leave it exactly as it is, no cap. both are valid, main character choices 🫢

See: wxPreviewFrame, wxPreviewCanvas, wxPrintPreview ⭐

This class is derived (and can use functions) from: wxPanel wxWindow wxEvtHandler β€” it's giving nepo baby but in a cute inherited-way πŸ‘‘

wxWidgets docs: wxPreviewControlBar πŸ“š


🧚 DATA TYPES 🧚

  • wxPreviewControlBar() = wx:wx_object()

πŸ”₯ EXPORTS πŸ”₯

πŸ’– new(Preview, Buttons, Parent) -> wxPreviewControlBar()

Types:

Preview = wxPrintPreview:wxPrintPreview()
Buttons = integer()
Parent = wxWindow:wxWindow()

πŸ’– new(Preview, Buttons, Parent, Options :: [Option]) -> wxPreviewControlBar()

Types:

Preview = wxPrintPreview:wxPrintPreview()
Buttons = integer()
Parent = wxWindow:wxWindow()
Option =
    {pos, {X :: integer(), Y :: integer()}} |
    {size, {W :: integer(), H :: integer()}} |
    {style, integer()}

Constructor, bestie ✨

The Buttons parameter may be a combination of the following, using the bitwise 'or' operator β€” yes, the actual bitwise or, do not come for me πŸ™ˆ


πŸ¦‹ destroy(This :: wxPreviewControlBar()) -> ok

Destructor. it destroys. that's the energy πŸ’€


πŸ¦‹ createButtons(This) -> ok

Types:

This = wxPreviewControlBar()

Creates buttons, according to value of the button style flags. slay, buttons created πŸ’…


πŸ¦‹ getPrintPreview(This) -> wxPrintPreview:wxPrintPreview()

Types:

This = wxPreviewControlBar()

Gets the print preview object associated with the control bar. it's giving "who's your preview bestie" πŸŽ€


πŸ¦‹ getZoomControl(This) -> integer()

Types:

This = wxPreviewControlBar()

Gets the current zoom setting in percent. no, not a vibe zoom, a literal percentage πŸ”


πŸ¦‹ setZoomControl(This, Percent) -> ok

Types:

This = wxPreviewControlBar()
Percent = integer()

Sets the zoom control. zoom zoom, periodt 🌈


✨ that's the whole page, bestie β€” every option, every type, every function, nothing skipped ✨

shoutout to the wxWidgets team for writing this, from wx 2.2.2.1, on this very wxPreviewControlBar(3erl) page πŸ«ΆπŸ’œ
πŸ“¦ where this page comes from