Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
Prima::StdBitmap(3)   User Contributed Perl Documentation  Prima::StdBitmap(3)

NAME
       Prima::StdBitmap	- shared access	to the standard	toolkit	bitmaps

DESCRIPTION
       The toolkit contains sysimage.gif image library,	which consists of a
       predefined set of images, used in several toolkit modules. To provide a
       unified access to the images this module	can be used. The images	are
       assigned	a "sbmp::" constant, which is used as an index on a load
       request.	If loaded successfully,	images are cached and the successive
       requests	return the cached values.

       The images can be loaded	as "Prima::Image" and "Prima::Icon" instances.
       To discriminate,	two methods are	used, correspondingly "image" and
       "icon".

SYNOPSIS
	  use Prima::StdBitmap;
	  my $logo = Prima::StdBitmap::icon( sbmp::Logo	);

API
   Methods
       icon INDEX
	   Loads INDEXth image frame and returns "Prima::Icon" instance.

       image INDEX
	   Loads INDEXth image frame and returns "Prima::Image"	instance.

       load_std_bmp %OPTIONS
	   Loads "index"th image frame from "file" and returns it as either a
	   "Prima::Image" or as	a "Prima::Icon"	instance, depending on value
	   of boolean "icon" flag. If "copy" boolean flag is unset, the	cached
	   images loaded previously can	be used. If this flag is set, the
	   cached value	is never used, and the created image is	not stored in
	   the cache. Since the	module's intended use is to provide shared and
	   read-only access to the image library, "copy" set to	1 can be used
	   to return non-shared	images.

	   The loader automatically scales images if system dpi	suggests so.
	   If layering is supported, the icon scaling will use that. To
	   disable these optimizations use "raw	=> 1" (to disable all)
	   construct, or "argb => 0" ( to disable ARGB icons ).

   Constants
       An index	value passed to	the methods must be one	of "sbmp::" constants:

	       sbmp::Logo
	       sbmp::CheckBoxChecked
	       sbmp::CheckBoxCheckedPressed
	       sbmp::CheckBoxUnchecked
	       sbmp::CheckBoxUncheckedPressed
	       sbmp::RadioChecked
	       sbmp::RadioCheckedPressed
	       sbmp::RadioUnchecked
	       sbmp::RadioUncheckedPressed
	       sbmp::Warning
	       sbmp::Information
	       sbmp::Question
	       sbmp::OutlineCollapse
	       sbmp::OutlineExpand
	       sbmp::Error
	       sbmp::SysMenu
	       sbmp::SysMenuPressed
	       sbmp::Max
	       sbmp::MaxPressed
	       sbmp::Min
	       sbmp::MinPressed
	       sbmp::Restore
	       sbmp::RestorePressed
	       sbmp::Close
	       sbmp::ClosePressed
	       sbmp::Hide
	       sbmp::HidePressed
	       sbmp::DriveUnknown
	       sbmp::DriveFloppy
	       sbmp::DriveHDD
	       sbmp::DriveNetwork
	       sbmp::DriveCDROM
	       sbmp::DriveMemory
	       sbmp::GlyphOK
	       sbmp::GlyphCancel
	       sbmp::SFolderOpened
	       sbmp::SFolderClosed
	       sbmp::Last

   Scalars
       $sysimage scalar	is initialized to the file name	to be used as a	source
       of standard image frames	by default. It is possible to alter this
       scalar at run-time, which causes	all subsequent image frame request to
       be redirected to	the new	file.

   Scaling
       Note: the module	scales the images automatically	with the resolution.
       Therefore it is advisable to use	the module's function after
       Application object is loaded.

AUTHOR
       Dmitry Karasik, <dmitry@karasik.eu.org>.

SEE ALSO
       Prima, Prima::Image, Prima::Const.

perl v5.24.1			  2017-02-28		   Prima::StdBitmap(3)

NAME | DESCRIPTION | SYNOPSIS | API | AUTHOR | SEE ALSO

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=Prima::StdBitmap&sektion=3&manpath=FreeBSD+12.0-RELEASE+and+Ports>

home | help