wxStaticBitmap(3erl)
π wxStaticBitmap π
okay so this is the wxStaticBitmap(3erl) page from the Erlang Module Definition manual, and bestie, itβs literally all about the wxStaticBitmap class. Weβre keeping every type, every arity, and every tiny caveat β no cap, no skipped details, just vibes and facts π
β¨
β¨ NAME β¨
wxStaticBitmap β Functions for wxStaticBitmap class. Short, iconic, to the point π
π¦ DESCRIPTION π¦
A static bitmap control displays a bitmap β thatβs the whole job, and itβs serving. Native implementations on some platforms are only meant for display of the small icons in the dialog boxes, so donβt expect them to be main-character big-image machines everywhere, iykyk.
If you want to display larger images portably, you may use generic implementation wxGenericStaticBitmap declared in <wx/generic/statbmpg.h>.
Heads up, bestie: for the best results, the size of the control should be the same as the size of the image displayed in it, as happens by default if itβs not resized explicitly. Otherwise, behaviour depends on the platform: under MSW, the bitmap is drawn centred inside the control, while elsewhere it is drawn at the origin of the control. You can use SetScaleMode() (not implemented in wx) to control how the image is scaled inside the control.
See: wxBitmap.
This class is derived (and can use functions) from: wxControl, wxWindow, wxEvtHandler.
wxWidgets docs: wxStaticBitmap.
π DATA TYPES π
wxStaticBitmap() = wx:wx_object()
yup, thatβs the type, and itβs giving wx:wx_object() energy π«Ά
π EXPORTS π
okay bestie, here come all the exports in order β every arity, every type, every see-reference. Buckle up π
πΈ new() -> wxStaticBitmap()
Default constructor. Literally the no-args default constructor, periodt.
π new(Parent, Id, Label) -> wxStaticBitmap()
Types:
Parent = wxWindow:wxWindow()
Id = integer()
Label = wxBitmap:wxBitmap()
This three-arg constructor is here with the basics: Parent, Id, and Label.
π¦ new(Parent, Id, Label, Options :: [Option]) -> wxStaticBitmap()
Types:
Parent = wxWindow:wxWindow()
Id = integer()
Label = wxBitmap:wxBitmap()
Option =
{pos, {X :: integer(), Y :: integer()}} |
{size, {W :: integer(), H :: integer()}} |
{style, integer()}
Constructor, creating and showing a static bitmap control. Yes, itβs doing both, and we love that for it.
See: create/5.
π
create(This, Parent, Id, Label) -> boolean()
Types:
This = wxStaticBitmap()
Parent = wxWindow:wxWindow()
Id = integer()
Label = wxBitmap:wxBitmap()
Here are the types for the four-arg create, clean and exact.
π₯ create(This, Parent, Id, Label, Options :: [Option]) -> boolean()
Types:
This = wxStaticBitmap()
Parent = wxWindow:wxWindow()
Id = integer()
Label = wxBitmap:wxBitmap()
Option =
{pos, {X :: integer(), Y :: integer()}} |
{size, {W :: integer(), H :: integer()}} |
{style, integer()}
Creation function, for two-step construction.
For details see new/4.
π getBitmap(This) -> wxBitmap:wxBitmap()
Types:
This = wxStaticBitmap()
Returns the bitmap currently used in the control.
Notice that this method can be called even if SetIcon() (not implemented in wx) had been used.
See: setBitmap/2.
π§ setBitmap(This, Label) -> ok
Types:
This = wxStaticBitmap()
Label = wxBitmap:wxBitmap()
Sets the bitmap label.
See: getBitmap/1.
β destroy(This :: wxStaticBitmap()) -> ok
Destroys the object. bye-bye object π
Catch u later, bestie! This page came from the wxWidgets team, version wx 2.2.2.1, under the wxStaticBitmap(3erl) banner β and the footer didnβt print a date, so weβre not inventing one. Keep slaying those static bitmaps π
β¨π«Ά
π¦ where this page comes from
- ubuntu noble: erlang-manpages 1:25.3.2.8+dfsg-1ubuntu4 Β· Apache-2.0
- ubuntu noble: erlang-manpages 1:25.3.2.8+dfsg-1ubuntu4.8 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms