Difference between revisions of "GFL Windows specific"
From XnView Wiki
(One intermediate revision by one other user not shown) | |||
Line 225: | Line 225: | ||
GFL_ERROR <b>gflImportFromHWND</b>( | GFL_ERROR <b>gflImportFromHWND</b>( | ||
HWND hwnd | HWND hwnd, | ||
const GFL_RECT* rect, | const GFL_RECT* rect, | ||
GFL_BITMAP** bitmap | GFL_BITMAP** bitmap | ||
Line 235: | Line 235: | ||
::Handle of the window. | ::Handle of the window. | ||
:rect | :rect | ||
::Pointer to [[Structures#GFL_RECT|GFL_RECT] structure. Rectangle to copy. | ::Pointer to [[Structures#GFL_RECT|GFL_RECT]] structure. Rectangle to copy. Can be NULL. | ||
:bitmap | |||
::Address of a pointer to a GFL_BITMAP structure. | |||
:Address of a pointer to a GFL_BITMAP structure. | |||
'''Return value''' | '''Return value''' | ||
:The function returns GFL_NO_ERROR if it is successful or a value of [[Error|GFL_ERROR]]. | :The function returns GFL_NO_ERROR if it is successful or a value of [[Error|GFL_ERROR]]. | ||
[[Category: GFLSDK Reference Manual]] |
Latest revision as of 18:18, 27 April 2010
gflConvertBitmapIntoDIB
The gflConvertBitmapIntoDIB function converts a GFL_BITMAP in a Windows Device Independant Bitmap.
GFL_ERROR gflConvertBitmapIntoDIB( const GFL_BITMAP* bitmap, HANDLE* hDIB );
Parameters
- bitmap
- Pointer to a GFL_BITMAP structure.
- hDIB
- Address of a DIB HANDLE.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflConvertBitmapIntoDDB
The gflConvertBitmapIntoDDB function converts a GFL_BITMAP in a Windows Device Dependant Bitmap.
GFL_ERROR gflConvertBitmapIntoDIB( const GFL_BITMAP* bitmap, HBITMAP* hBitmap );
Parameters
- bitmap
- Pointer to a GFL_BITMAP structure.
- hBitmap
- Address of a HBITMAP.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflConvertDIBIntoBitmap
The gflConvertDIBIntoBitmap function converts a Windows Device Independant Bitmap into GFL_BITMAP.
GFL_ERROR gflConvertDIBIntoBitmap( HANDLE hDIB, GFL_BITMAP** bitmap );
Parameters
- hDIB
- A HANDLE on the DIB.
- bitmap
- Address of a pointer to a GFL_BITMAP structure.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflConvertDDBIntoBitmap
The gflConvertDDBIntoBitmap function converts a Windows Device Dependant Bitmap into GFL_BITMAP.
GFL_ERROR gflConvertDDBIntoBitmap( HBITMAP hBitmap, GFL_BITMAP** bitmap );
Parameters
- hBitmap
- A HANDLE on the HBITMAP.
- bitmap
- Address of a pointer to a GFL_BITMAP structure.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflLoadBitmapIntoDIB
The gflLoadBitmapIntoDIB function loads a picture file into a Windows Device Independant Bitmap.
GFL_ERROR gflLoadBitmapIntoDIB( const char* filename, HANDLE* hDIB, GFL_LOAD_PARAMS* params, GFL_FILE_INFORMATION* informations );
Parameters
- filename
- Pointer to a null-terminated string that contains the filename to load.
- hDIB
- Address of a DIB HANDLE.
- params
- Pointer to a GFL_LOAD_PARAMS structure.
- This structure must be filled correctly.
- informations
- Pointer to a GFL_FILE_INFORMATION structure. Can be NULL if you don't want it.
- You must use gflFreeInformation to free his content.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflLoadBitmapIntoDDB
The gflLoadBitmapIntoDDB function loads a picture file into a Windows Device Dependant Bitmap.
GFL_ERROR gflLoadBitmapIntoDDB( const char* filename, HBITMAP* hBitmap, GFL_LOAD_PARAMS* params, GFL_FILE_INFORMATION* informations );
Parameters
- filename
- Pointer to a null-terminated string that contains the filename to load.
- hBitmap
- Address of a HBITMAP.
- params
- Pointer to a GFL_LOAD_PARAMS structure.
- This structure must be filled correctly.
- informations
- Pointer to a GFL_FILE_INFORMATION structure. Can be NULL if you don't want it.
- You must use gflFreeInformation to free his content.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflAddText
The gflAddText function adds a text on a GFL_BITMAP.
GFL_ERROR gflAddText( GFL_BITMAP* bitmap, const char* text, const char* font_name, GFL_INT32 x, GFL_INT32 y, GFL_INT32 font_size, GFL_INT32 orientation, GFL_BOOL italic, GFL_BOOL bold, GFL_BOOL strike_out, GFL_BOOL underline, GFL_BOOL antialias, const GFL_COLOR* color );
Parameters
- bitmap
- Pointer to a GFL_BITMAP structure.
- text
- Pointer to a null-terminated string that contains the text to add.
- font_name
- Pointer to a null-terminated string that contains the name of the font to use.
- x
- X position.
- y
- Y position.
- font_size
- Height of the font.
- orientation
- Orientation of the text (degrees).
- italic
- Specifies a italic font.
- bold
- Specifies a bold font.
- strike_out
- Specifies a strikeout font.
- underline
- Specifies a underline font.
- antialias
- Font is antialiased.
- color
- Pointer to a GFL_COLOR structure for the text color.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflImportFromClipboard
The gflImportFromClipboard function allows to import the picture from the clipboard. .
GFL_ERROR gflImportFromClipboard( GFL_BITMAP** bitmap );
Parameters
- bitmap
- Address of a pointer to a GFL_BITMAP structure.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflExportIntoClipboard
The gflExportIntoClipboard function allows to export a picture into clipboard..
GFL_ERROR gflExportIntoClipboard( GFL_BITMAP* bitmap );
Parameters
- bitmap
- Pointer to a GFL_BITMAP structure.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.
gflImportFromHWND
The gflImportFromHWND function allows to copy the content of a window. .
GFL_ERROR gflImportFromHWND( HWND hwnd, const GFL_RECT* rect, GFL_BITMAP** bitmap );
Parameters
- hwnd
- Handle of the window.
- rect
- Pointer to GFL_RECT structure. Rectangle to copy. Can be NULL.
- bitmap
- Address of a pointer to a GFL_BITMAP structure.
Return value
- The function returns GFL_NO_ERROR if it is successful or a value of GFL_ERROR.