wxPreviewFrame(3erl)

πŸŽ€ wxPreviewFrame (3erl): Erlang Module Definition πŸŽ€

okay so this is the wxPreviewFrame(3erl) manual page, aka the Erlang Module Definition, and we are gonna make it make sense πŸ’–

🌸 NAME 🌸

wxPreviewFrame - Functions for wxPreviewFrame class. That's the whole name vibe 🫢

✨ DESCRIPTION ✨

okay so this class provides the default method of managing the print preview interface. Member functions may be overridden to replace functionality, or the class may be used without derivation β€” both routes are valid, bestie ✨

  • See: wxPreviewCanvas, wxPreviewControlBar, wxPrintPreview.
  • This class is derived (and can use functions) from: wxFrame wxTopLevelWindow wxWindow wxEvtHandler.
  • wxWidgets docs: wxPreviewFrame.

πŸŽ€ DATA TYPES πŸŽ€

wxPreviewFrame() = wx:wx_object()

that's the type, iconic πŸ’…

πŸ’… EXPORTS πŸ’…

🌸 new(Preview, Parent) -> wxPreviewFrame() 🌸

Types:

  • Preview = wxPrintPreview:wxPrintPreview()
  • Parent = wxWindow:wxWindow()

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

Types:

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

Constructor. Pass a print preview object plus other normal frame arguments. The print preview object will be destroyed by the frame when it closes 🫢

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

Destructor. That's it, that's the whole destructor vibe πŸ’€

πŸŽ€ createControlBar(This) -> ok πŸŽ€

Types:

  • This = wxPreviewFrame()

Creates a wxPreviewControlBar.

Override this function to allow a user-defined preview control bar object to be created β€” custom control bar era ✨

🌈 createCanvas(This) -> ok 🌈

Types:

  • This = wxPreviewFrame()

Creates a wxPreviewCanvas.

Override this function to allow a user-defined preview canvas object to be created β€” custom canvas moment, iykyk 🎨

⭐ initialize(This) -> ok ⭐

Types:

  • This = wxPreviewFrame()

Initializes the frame elements and prepares for showing it.

Calling this method is equivalent to calling InitializeWithModality() (not implemented in wx) with wxPreviewFrame_AppModal argument, please see its documentation for more details.

⚠️ Please notice that this function is virtual mostly for backwards compatibility only, there is no real need to override it as it's never called by wxWidgets itself.

πŸ’œ onCloseWindow(This, Event) -> ok πŸ’œ

Types:

  • This = wxPreviewFrame()
  • Event = wxCloseEvent:wxCloseEvent()

Enables any disabled frames in the application, and deletes the print preview object, implicitly deleting any printout objects associated with the print preview object.


Big cute sign-off: shoutout to the wxWidgets team β€” this page is source/version wx 2.2.2.1, for wxPreviewFrame(3erl). Bye bestie, go slay your print previews πŸ’…βœ¨

πŸ“¦ where this page comes from