Class: Fox::FXBMPIcon
- Defined in:
- rdoc-sources/FXBMPIcon.rb
Overview
The BMP Icon class is a convenience class for working with icons in the Microsoft Bitmap (.bmp) graphics file format. This makes it possible to use resources created with Windows development tools inside FOX without need for graphics file format translators. The bitmap loaded handles 1, 4, and 8 bit paletted bitmaps, 16 and 24 bit RGB bitmaps, and 32 bit RGBA bitmaps.
Instance Attribute Summary
Attributes inherited from FXIcon
Attributes inherited from FXImage
#data, #dataPtr, #options, #pixels
Attributes inherited from FXDrawable
Attributes inherited from FXId
Class Method Summary collapse
-
.fileExt ⇒ Object
Return the suggested file extension for this image type (“bmp”).
-
.mimeType ⇒ Object
Return the MIME type for this image type.
Instance Method Summary collapse
-
#initialize(a, pix = nil, clr = Fox.FXRGB(192,192,192), opts = 0, width = 1, height = 1) ⇒ FXBMPIcon
constructor
Return an initialized FXBMPIcon instance.
Methods inherited from FXImage
#blend, #crop, #fade, #fill, #getPixel, #gradient, #hasAlpha?, #hgradient, #initialize_without_data_string, #loadPixels, #mirror, #pixel_string, #release, #render, #restore, #rotate, #savePixels, #scale, #setPixel, #setPixels, #setPixels_without_data_string, #vgradient, #xshear, #yshear
Methods inherited from FXDrawable
Methods inherited from FXId
#create, #created?, #destroy, #detach, #runOnUiThread
Methods inherited from FXObject
#bind, #handle, #load, #save, subclasses
Constructor Details
#initialize(a, pix = nil, clr = Fox.FXRGB(192,192,192), opts = 0, width = 1, height = 1) ⇒ FXBMPIcon
Return an initialized FXBMPIcon instance.
Parameters:
a
-
an application instance Fox::FXApp
pix
-
a memory buffer formatted in BMP file format [String]
clr
-
transparency color Fox::FXColor
opts
-
options [Integer]
width
-
width [Integer]
height
-
height [Integer]
33 34 |
# File 'rdoc-sources/FXBMPIcon.rb', line 33 def initialize(a, pix=nil, clr=Fox.FXRGB(192,192,192), opts=0, width=1, height=1) # :yields: theBMPIcon end |
Class Method Details
.fileExt ⇒ Object
Return the suggested file extension for this image type (“bmp”).
14 |
# File 'rdoc-sources/FXBMPIcon.rb', line 14 def FXBMPIcon.fileExt; end |
.mimeType ⇒ Object
Return the MIME type for this image type
19 |
# File 'rdoc-sources/FXBMPIcon.rb', line 19 def FXBMPIcon.mimeType; end |