Prima::Application(3)
π¦ Prima::Application β the root of the widget hierarchy π¦
okay bestie, this is the Prima::Application(3) page from the User Contributed Perl Documentation, and we're folding that manual name in right here at the top so it doesn't have to sit by itself like an awkward header line. π This whole page is about the root of the widget hierarchy β the main-character app object that owns basically everything. β¨
πΈ NAME πΈ
Prima::Application β the root of the widget hierarchy.
π DESCRIPTION π
The Prima::Application class? She's the hierarchy root for the majority of Prima objects. All toolkit widgets are ultimately owned by the application object. And no cap: there can be only one instance of the Prima::Application class at a time. π
π SYNOPSIS π
use Prima qw(Application);
Prima::MainWindow->new();
run Prima;
π USAGE π
okay so the Prima::Application class and its only instance are treated in a special way in the toolkit's paradigm. Its only object instance is stored in the
$::application
scalar, defined in Prima.pm module. The application instance must be created whenever a widget, window, or event loop functionality is needed. Usually the
use Prima::Application;
or
use Prima qw(Application);
code is enough, but $::application can also be created and assigned explicitly. The 'use' syntax has an advantage as more resistant to eventual changes in the toolkit design. It can also be used in conjunction with custom parameters hash like the new() syntax:
use Prima::Application name => 'Test application', icon => $icon;
In addition to this functionality, Prima::Application is also a wrapper to a set of system functions, not directly related to the object classes. This functionality is generally explained in API.
𧬠Inherited functionality π§¬
Prima::Application is a descendant of Prima::Widget but does not conform strictly ( in the OO sense ) to any of the built-in classes. It has methods from both Prima::Widget and Prima::Window, also, the methods inherited from the Prima::Widget class may work quite differently. For example, the ::origin property from Prima::Widget is also implemented in Prima::Application, but always returns (0,0), an expected but not much usable result. The ::size property, on the contrary, returns the extent of the screen in pixels. There are a few properties inherited from Prima::Widget, which return actual but uninformative results, - ::origin is one of those, but there are several others. The methods and properties, that are like ::size providing different functionality, are described separately in API.
π Global functionality π
Prima::Application is a wrapper to a set of unrelated functions that do not belong to other classes. A notable example, the painting functionality that is inherited from the Prima::Drawable class, allows drawing on the screen, possibly overwriting the graphic information created by the other programs. Although it is still a subject to the begin_paint()/end_paint() brackets, this functionality does not belong to a single object and is considered global.
π¨ Painting π¨
As stated above, the Prima::Application class provides an interface to the on-screen painting. This mode is triggered by the begin_paint()/end_paint() methods, while the other pair, begin_paint_info()/end_paint_info() triggers the information mode. This three-state paint functionality is more thoroughly described in Prima::Drawable.
The painting on the screen surfaces under certain environments (XQuartz, XWayland) is either silently ignored or results in an error. There, begin_paint may return a false value (begin_paint_info though always true).
π‘ Hints π‘
$::application hosts a special Prima::HintWidget class object, accessible via get_hint_widget(), but with its color and font functions aliased ( see ::hintColor, ::hintBackColor, ::hintFont ).
This widget serves as a hint label, floating over other widgets if the mouse pointer hovers longer than ::hintPause milliseconds.
Prima::Application internally manages all of the hint functionality. The hint widget itself, however, can be replaced before the application object is created, using the ::hintClass create-only property.
π¨οΈ Printer π¨οΈ
The result of the get_printer method points to an automatically created printer object, responsible for the system printing. Depending on the operating system, it is either Prima::Printer, if the system provides GUI printing capabilities, or generic Prima::PS::Printer, the PostScript/PDF document interface.
See Prima::Printer for details.
π Clipboard π
$::application hosts a set of Prima::Clipboard objects created automatically to reflect the system-provided clipboard IPC functionality. Their number depends on the system, - under the X11 environment, there are three clipboard objects, and one under Win32.
There are no specific methods to access these clipboard objects, except bring() ( or the indirect name call ); the clipboard objects are named after the system clipboard names, which are returned by the Prima::Clipboard::get_standard_clipboards method.
The default clipboard is named Clipboard, and is accessible via the
my $clipboard = $::application-> Clipboard;
call.
See Prima::Clipboard for details.
π Help subsystem π
The toolkit has a built-in help viewer, that understands perl's native POD ( plain old documentation ) format. Whereas the viewer functionality itself is a part of the toolkit that resides in the Prima::HelpViewer module, any custom help viewing module can be assigned. The create-only Prima::Application properties ::helpClass and ::helpModule can be used to set these options.
Prima::Application provides two methods for communicating with the help viewer window: open_help() opens a selected topic in the help window, and close_help() closes the window.
π₯οΈ System-dependent information π₯οΈ
A complex program will need eventually more information than the toolkit provides. Knowing the toolkit boundaries in some platforms, the program may change its behavior accordingly. Both these topics are facilitated by extra system information returned by Prima::Application methods. The get_system_value method returns a system-defined value for each of the sv::XXX constants, so the program can read the system-specific information. Another method get_system_info returns the short description of the system that augments perl's $^O variable.
The sys_action method is a wrapper to system-dependent functionality that is called in a non-portable way. This method is rarely used in the toolkit, its usage is discouraged, primarily because its options do not serve the toolkit design, its syntax is subject to changes, and cannot be relied upon.
π¨ Exceptions and signals π¨
By default Prima doesn't track exceptions caused by die, warn, and signals. Currently, it is possible to enable a GUI dialog tracking the die exceptions, by either operating the boolean guiException property or using the
use Prima qw(sys::GUIException)
syntax.
If you need to track signals or warnings you may do so by using standard perl practices. It is though not advisable to call Prima interactive methods directly inside signal handlers but use a minimal code instead. F.ex. code that would ask whether the user wants to quit would look like this:
use Prima qw(Utils MsgBox);
$SIG{INT} = sub {
Prima::Utils::post( sub {
exit if message_box("Got Ctrl+C", "Do you really want to quit?", mb::YesNo) == mb::Yes;
});
};
and if you want to treat all warnings as potentially fatal, like this:
use Prima qw(Utils MsgBox);
$SIG{__WARN__} = sub {
my ($warn, $stack) = ($_[0], Carp::longmess);
Prima::Utils::post( sub {
exit if $::application && Prima::MsgBox::signal_dialog("Warning", $warn, $stack) == mb::Abort;
});
};
See also: Die, "signal_dialog" in Prima::MsgBox
π₯ API π₯
π Properties π
autoCloseBOOLEAN β if set to1, issuesclose()after the last top-level window is destroyed. Does not influence anything if set to0.
This feature is designed to help with generic 'one main window' application layouts.
Default value: 0
guiExceptionBOOLEAN β if set to1, when adieexception is thrown, displays a system message dialog, allowing the user to choose the course of action -- to stop, to continue, etc.
Is 0 by default.
Note that the exception is only handled inside the Prima::run and Prima::Dialog::execute calls; if there is a call to f ex Prima::Window::execute or a manual event loop run with yield, the signal dialog will not be shown. One needs to explicitly call $::application->notify(Die => $@) and check the notification result to decide whether to propagate the exception or not.
The alternative syntax for setting guiException to 1 is the
use Prima::sys::GUIException;
or
use Prima qw(sys::GUIException);
statement.
If for some reason an exception is thrown during dialog execution, it will not be handled by Prima but by the current $SIG{__DIE__} handler.
See also: "signal_dialog" in Prima::MsgBox .
iconOBJECT β holds the icon object associated with the application. Ifundef, the system-provided default icon is assumed.Prima::Windowobjects inherit this application icon by default.insertModeBOOLEAN β the system boolean flag signaling whether text widgets through the system should insert (1) or overwrite (0) text on user input. Not all systems provide the global state of the flag.helpClassSTRING β specifies the class of the object used as the help viewing package. The default value isPrima::HelpViewer. Run-time changes to the property do not affect the help subsystem until a call toclose_helpis made.helpModuleSTRING β specifies the perl module loaded indirectly when a help viewing call is made via theopen_helpmethod. Used when the::helpClassproperty is overridden and the new class is contained in a third-party module. Run-time changes to the property do not affect the help subsystem until a call toclose_helpis made.hintClassSTRING β create-only property.
Specifies the class of the widget used as the hint label.
Default value: Prima::HintWidget
hintColorCOLOR β the alias to the foreground color property of the hint label widget.hintBackColorCOLOR β the alias to the background color property of the hint label widget.hintFont%FONT β the alias to the font property of the hint label widget.hintPause TIMEOUTβ sets how long, in milliseconds, the pointer has to just chill hovering over a widget before the hint label pops up. Basically the patience setting of your app π«Άlanguage STRINGβ by default this holds the UI language, which gets deduced either from the$ENV{LANG}environment variable (on unix) or from a system default setting (on win32). Change it and thetextDirectionproperty gets updated too, slay π¦
See also: get_system_info.
modalHorizon BOOLEANβ read-only, bestie. it's the lowest-level modal horizon and it always returns1. no notes. iconic behaviour honestly πpalette [ @PALETTE ]β only used inside the paint and information modes. it picks solid colors in the system palette, as many as it possibly can.PALETTEis an array of 8-bit integer triplets, and each triplet is a red, a green and a blue component πprinterClass STRINGβ create-only property β¨
it specifies the class of the object used as the printer. the default value is system-dependent, but it's either Prima::Printer or Prima::PS::Printer.
printerModule STRINGβ create-only property β¨
specifies the perl module that gets loaded indirectly before the printer object of the ::printerClass class is created. you need this when the ::printerClass property is overridden and the new class lives inside a third-party module.
pointerVisible BOOLEANβ manages the system pointer visibility. if it's0, the pointer is hidden so it's not visible in all system windows, so likeβ¦ use this one with care, fr fr πsize WIDTH, HEIGHTβ read-only. returns two integers, the width and height of the screen πshowHint BOOLEANβ if1, the toolkit is allowed to show the hint label over a widget. if0, showing the hint is forbidden. on top of the functionality of the::showHintproperty in Prima::Widget,Prima::Application::showHintis another layer of hint visibility control β if it's0, all hint actions are disabled, ignoring whatever::showHintvalue the widgets have. double lock, no cap πskin SCALARβ same asskinin Prima::Widget, but it's mentioned here because you can change the whole application's skin just by setting this property, f ex like this:
use Prima::Application skin => 'flat';
textDirection BOOLEANβ contains the preferred text direction, initially deduced from the preferred interface language. if0(the default), the preferred text direction is left-to-right (LTR), otherwise right-to-left (RTL), f.ex. for Arabic and Hebrew languages πΈ
this value gets used as the default when shaping text and when setting widget input direction.
uiScaling FLOATβ an advisory multiplier factor, and it's genuinely so useful for UI elements that have a fixed pixel value but would like to look reasonable when the display resolution is too high (modern High-DPI displays, we see you) or too low (ancient monitors, we see you too) π
by default it grabs the system display resolution and sets the scaling factor so that when the DPI is 96 it's 1.0, 192 it's 2.0, etc. the increase step is 0.25, so bitmaps won't look that distorted when scaled. but when you set the value manually, the step is not enforced and any value can be accepted β free will, periodt β¨
See also: Stress in Prima.
wantUnicodeInput BOOLEANβ selects whether the system is allowed to generate key codes in unicode. returns the effective state of the unicode input flag, which cannot be changed if perl or the operating system doesn't support UTF8 π
if 1, the Prima::Clipboard::text property may return UTF8 text from the system clipboards if available.
default value: 1
β¨ EVENTS β¨
Clipboard $CLIPBOARD, $ACTION, $TARGETβ with (the only implemented)$ACTIONcopy, this fires whenever another application requests clipboard data in the format$TARGET. it's handled internally so image pasting through the clipboard can be optimised. here's the situation: clipboard pasting semantics in Prima are such that data has to be supplied to the clipboard in advance, before another application can request it β so which format do you even pick?? rather than encoding an image or other complex data in all possible formats, you do it on demand in whatever format the other application wants, and this notification is your girl π
only implemented for X11.
CopyImage $CLIPBOARD, $IMAGEβ the notification stores$IMAGEin the clipboard πΌοΈCopyText $CLIPBOARD, $TEXTβ the notification stores$TEXTin the clipboard πDie $@, $STACKβ called when an exception occurs inside the event loopPrima::run. by default it consults theguiExceptionproperty, and if that's set, it displays the system message dialog letting the user decide what to do next πIdleβ called when the event loop has handled all pending events and is about to go to sleep waiting for more. nap time bestie π΄PasteImage $CLIPBOARD, $$IMAGE_REFβ the notification queries$CLIPBOARDfor image content and stores it in$$IMAGE_REF. the default action is that the'Image'format is queried. on unix, encoded formats'image/bmp','image/png'etc are queried if the default'Image'is not found π¦
the PasteImage mechanism can read images from the clipboard in the GTK environment.
PasteText $CLIPBOARD, $$TEXT_REFβ the notification queries$CLIPBOARDfor text content and stores it in the$$TEXT_REFscalar. its default action is that only the'Text'format is queried ifwantUnicodeInputis unset. otherwise, the'UTF8'format is queried first π
the PasteText mechanism exists to make defining text unicode/ascii conversion between clipboard and standard widgets easy, in a unified way. lowkey genius.
β¨ METHODS β¨
add_startup_notification @CALLBACKβCALLBACKis an array of anonymous subs, and all of them get executed when the Prima::Application object is created. if the application object already exists by the time you call this, theCALLBACKs are called immediately, no waiting around π
super useful for initializing add-on packages.
begin_paintβ enters the enabled (active paint) state and returns the success flag. once the object is in the enabled state, painting and drawing methods can perform drawing operations on the whole screen π¨begin_paint_infoβ enters the information state and returns the success flag. the object's information state is the same as the enabled state (seebegin_paint), except that painting and drawing methods are not permitted to change the screen.closeβ issues a system termination call, which results in calling theclosemethod for all top-level windows. that call can be interrupted by those windows and effectively canceled. if it's not canceled, it stops the application event loop πͺclose_helpβ closes the help viewer window.end_paintβ quits the enabled state and returns the application object to the normal state.end_paint_infoβ quits the information state and returns the application object to the normal state.font_encodingsβ returns an array of encodings as strings, the ones the system recognizes and that are available for at least one font. every system hands you a different set of encoding strings, so heads up: font encodings are not portable πfonts NAME = '', ENCODING = ''β returns a hash of font hashes (seeFontsin Prima::Drawable) describing fonts of theNAMEfont family and of theENCODINGtext encoding. ifNAMEis''orundef, it returns one font hash for each of the font families that match theENCODINGstring. ifENCODINGis''orundef, no encoding match is performed. ifENCODINGis not valid (i.e. not present in thefont_encodingsresult), it's treated as if it were''orundefπ§
in the special case where both NAME and ENCODING are '' or undef, each font metric hash contains the element encodings, which points to an array of the font encodings available for the fonts of the NAME font family. so much info, we love to see it.
get_active_windowβ returns the object reference to the currently active window, if there is any, that belongs to the program. if no such window exists,undefis returned.
the exact definition of 'active window' is system-dependent, but it's generally believed that an active window is the one that has keyboard focus on one of its children widgets π
get_caption_fontβ returns the title font the system uses to draw top-level window captions. you can call this method with a class string instead of an object instance πΈget_default_cursor_widthβ returns the width of the system cursor in pixels. can be called with a class string instead of an object instance.get_default_fontβ returns the default system font. can be called with a class string instead of an object instance β¨get_default_scrollbar_metricsβ returns the dimensions of the system scrollbars: the width of the standard vertical scrollbar and the height of the standard horizon scrollbar. can be called with a class string instead of an object instance.get_dnd_clipboardβ returns the predefined special clipboard used as a proxy for drag-and-drop interactions π«Ά
See also: Widget/Drag and drop, Clipboard/is_dnd.
get_default_window_borders BORDER_STYLE = bs::Sizeableβ returns the width and height of the standard system window border decorations for one of thebs::XXXconstants. can be called with a class string instead of an object instance.get_focused_widgetβ returns the object reference to the currently focused widget, if there is any, that belongs to the program. if no such widget exists,undefis returned.get_fullscreen_imageβ syntax sugar for grabbing the whole screen, like so:
$::application->get_image( 0, 0, $::application->size)
(MacOSX/XQuartz note: get_image() does not grab all screen bits, but get_fullscreen_image does if Prima is compiled with the Cocoa library π)
get_hint_widgetβ returns the hint label widget, which gets attached automatically to the Prima::Application object during startup. the widget is of the::hintClassclass, Prima::HintWidget by default πget_image X_OFFSET, Y_OFFSET, WIDTH, HEIGHTβ bestie, this is the screen-grab icon π It returns aPrima::Imageobject withWIDTHandHEIGHTdimensions, filled with the graphic content of the screen copied from theX_OFFSETandY_OFFSETcoordinates. IfWIDTHandHEIGHTextend beyond the screen dimensions, they get adjusted. If the offsets are outside the screen boundaries, or ifWIDTHandHEIGHTare zero or negative,undefis returned.
Note: when you're running on MacOSX under XQuartz, XQuartz does not give access to the whole screen, so this function won't be able to grab the top-level menu bar π That exact problem is handled by the get_fullscreen_image method.
get_indentsβ returns 4 integers that correspond to extensions of eventual desktop decorations that the windowing system may present on the left, bottom, right, and top edges of the screen. For example, on win32 this reports the size of the part of the screen that the windows taskbar may occupy, if any πͺget_printerβ returns the printer object attached automatically to thePrima::Applicationobject. That object is an instance of the::printerClassclass π¨οΈβ¨get_message_fontβ returns the font the system uses to draw the message text. This method can be called with a class string instead of an object instance πget_modal_window MODALITY_TYPE = mt::Exclusive, TOPMOST = 1β returns the modal window that resides on an end of the modality chain.MODALITY_TYPEselects the chain, and it can be eithermt::Exclusiveormt::Shared.TOPMOSTis a boolean flag selecting the lookup direction: if it is1, the 'topmost' window is returned; if it is0, the 'lower-most' one is returned (in a simple case when window A is made modal / executed after modal window B, the A window is the 'topmost' one π).
If the chain is empty, undef is returned. In case the chain consists of just one window, the TOPMOST value is irrelevant πββοΈ
get_monitor_rectsβ returns a set of rectangles in the format of(X,Y,WIDTH,HEIGHT)identifying monitor layouts π₯οΈπ₯οΈget_scroll_rateβ returns two integer values of two system-specific scrolling timeouts. The first is the initial timeout that is applied when the user drags the mouse from a scrollable widget (a text field, for example), and the widget is about to scroll, but the actual scroll is performed after the timeout has expired. The second value is the repetitive timeout: if the dragging condition did not change, the scrolling performs automatically after this timeout. The timeout values are in milliseconds β±οΈget_system_infoβ returns a hash with the following keys containing information about the system:apcβ one of theapc::XXXconstants reporting the platform the program is running on. Currently, the list of supported platforms is one of these two:apc::Win32apc::Unix
guiβ one of thegui::XXXconstants reporting the graphic user interface used in the system:gui::Defaultgui::Windowsgui::XLibgui::GTK
guiDescriptionβ description of the graphic user interface, returned as an arbitrary string.guiLanguageβ the preferred language of the interface, returned as an ISO 639 code.systemβ an arbitrary string representing the operating system software.releaseβ an arbitrary string containing the OS version information.vendorβ the OS vendor string.architectureβ the machine architecture string.
The method can be called with a class string instead of an object instance π§
get_system_valueβ returns the system integer value associated with one of thesv::XXXconstants. The constants are:sv::YMenuβ height of menu bar in top-level windows.sv::YTitleBarβ height of title bar in top-level windows.sv::XIcon,sv::YIconβ width and height of main icon dimensions acceptable by the system.sv::XSmallIcon,sv::YSmallIconβ width and height of alternate icon dimensions acceptable by the system.sv::XPointer,sv::YPointerβ width and height of mouse pointer icon acceptable by the system.sv::XScrollbarβ width of the default vertical scrollbar.sv::YScrollbarβ height of the default horizontal scrollbar (seeget_default_scrollbar_metrics()).sv::XCursorβ width of the system cursor (seeget_default_cursor_width()).sv::AutoScrollFirst,sv::AutoScrollNextβ the initial and the repetitive scroll timeouts (seeget_scroll_rate()).sv::InsertModeβ the system insert mode (seeinsertMode).sv::XbsNone,sv::YbsNoneβ width and height of the top-level window decorations withborderStylebs::None(seeget_default_window_borders()).sv::XbsSizeable,sv::YbsSizeableβ width and height of the top-level window decorations withborderStylebs::Sizeable(seeget_default_window_borders()).sv::XbsSingle,sv::YbsSingleβ width and height of the top-level window decorations withborderStylebs::Single(seeget_default_window_borders()).sv::XbsDialog,sv::YbsDialogβ width and height of the top-level window decorations withborderStylebs::Dialog(seeget_default_window_borders()).sv::MousePresentβ1if the mouse is present,0otherwise.sv::MouseButtonsβ number of the mouse buttons.sv::WheelPresentβ1if the mouse wheel is present,0otherwise.sv::SubmenuDelayβ timeout (in ms) before a sub-menu shows on an implicit selection.sv::FullDragβ1if the top-level windows are dragged dynamically,0with marquee mode.sv::DblClickDelayβ mouse double-click timeout in milliseconds.sv::ShapeExtensionβ1ifPrima::Widget::shapefunctionality is supported,0otherwise.sv::ColorPointerβ1if the system accepts color pointer icons.sv::CanUTF8_Inputβ1if the system can generate key codes in unicode.sv::CanUTF8_Outputβ1if the system can output utf8 text.sv::CompositeDisplayβ1if the system uses double-buffering and alpha composition for the desktop,0if it doesn't,-1if unknown.sv::LayeredWidgetsβ1if the system supports layering.sv::FixedPointerSizeβ0if the system doesn't support arbitrarily sized pointers and will resize custom icons to the system size.sv::MenuCheckSizeβ width and height of default menu check icon.sv::FriBidiβ1if Prima is compiled with libfribidi and full bidi unicode support is available.sv::Antialiasβ1if the system supports antialiasing and alpha layer for primitives.sv::LibThaiβ1if Prima is compiled with libthai.
The method can be called with a class string instead of an object instance πΈ
get_widget_from_handle HANDLEβHANDLEis an integer value of a toolkit widget handle as used in the underlying GUI level; for example, it is aHWNDvalue on win32. It is usually passed to the program by other IPC means, so that the method can return the associated widget. If no widget is associated withHANDLE,undefis returned πget_widget_from_point X_OFFSET, Y_OFFSETβ returns the widget that occupies the screen area under the(X_OFFSET,Y_OFFSET)coordinates. If no toolkit widgets are found,undefis returned πgoβ the main event loop. Called by the standard code:
run Prima;
It returns when the program is about to terminate, if stop was called, or if an exception was signaled. In the latter two cases, the loop can be safely restarted π
lockβ effectively blocks the graphic output for all widgets. The output can be restored withunlock()πload_font FONTNAMEβ registers a font resource in the system-specific format. The resource is freed after the program ends.
Notes for win32: to add a font whose information comes from several resource files, point FONTNAME to a string with the file names separated by a | β for example, abcxxxxx.pfm | abcxxxxx.pfb.
Notes for unix: available only when Prima is compiled with fontconfig and Xft.
Returns the number of the font resources added π€β¨
open_help TOPICβ opens the help viewer window with theTOPICstring in the link POD format (seeperlpod). The string is treated asmanpage/section, where 'manpage' is the file with POD content and 'section' is the topic inside the manpage.
Alternatively, it can handle the syntax in the form of file://path|section, where path is the file with the pod content and section is an optional pod section within the file ππ¦
stopβ stops the event loop. The loop can be started again πsyncβ synchronizes all pending requests where there are any. It is an effectiveXSync(false)on X11, and it is a no-op otherwise πsys_action CALLβCALLis an arbitrary string of the system service name and the parameters to it. This functionality is non-portable, and its usage should be avoided. The system services provided are not documented and are subject to change. The actual services can be looked at in the toolkit source code under theapc_system_actiontag β οΈunlockβ unlocks the graphic output for all widgets previously locked withlock()πyield $wait_for_event=0β an event dispatcher, called from within the event loop. If the event loop can be schematized, then in this code:
while ( application not closed ) {
yield
}
yield() is the only function called repeatedly inside the loop. The yield(0) call shouldn't be used to organize event loops, but it can be employed to process stacked system events explicitly, to increase the responsiveness of a program β for example, inside a long calculation cycle π«
Okay so yield(1)? That one's adapted exactly for when you're implementing event loops externally, like off in your own little world π It does the same thing as yield(0), except β and this is the moment β if there are no events waiting, it sleeps until at least one shows up, processes it, and then returns π΄β‘οΈβ‘ So it's the patient bestie of the two.
The return value is 0 if the application doesn't need any more event processing, which happens because it's shutting down π So the corresponding code is literally:
while ( yield(1)) {
...
}
But β and I need you to hear me on this one β this call cannot be used for increasing UI responsiveness inside tight calculation loops π« Like, don't try to sneak it into your number-crunching to make the window feel snappy, that's not what she's for, no cap π
Oh and plot twist: the method can be called with a class string instead of an object instance π However, the $::application object must be initialized. Non-negotiable, bestie β¨
π AUTHOR
Dmitry Karasik, <dmitry@karasik.eu.org> π (shoutout to the icon who made all this happen, we stan fr fr π«Ά)
πΈ SEE ALSO
PrimaPrima::ObjectPrima::WidgetPrima::Window
Go read those next, they're the whole ecosystem and you're gonna want the full tour π¦
And that's the page!! π This little gem is from perl v5.42.0, dated 2024-08-20, and it's the Prima::Application(3) manpage β go forth and slay your event loop π
β¨
π¦ where this page comes from
- opensuse-leap 16.0: perl-Prima 1.74000-bp160.1.13 Β· AGPL-3.0-only AND BSD-2-Clause
- opensuse-leap 16.0: perl-Prima 1.74000-bp160.1.13 Β· AGPL-3.0-only AND BSD-2-Clause
- opensuse-leap 16.0: perl-Prima 1.74000-bp160.1.13 Β· AGPL-3.0-only AND BSD-2-Clause
- opensuse-leap 16.0: perl-Prima 1.74000-bp160.1.13 Β· AGPL-3.0-only AND BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms