MITSUBISHI CNC NC Designer Reference Manual

Page 1
Page 2
MELDAS is a registered trademark of Mitsubishi Electric Corporation. Other product names and company names are trademarks or registered trademarks of their respective companies.
Page 3

Introduction

This manual is a guide for users of NC Designer for the Mitsubishi CNC700/70 series. This manual describes the function groups used in NC Designer. In addition, fully understand "Precautions for Safety" on the next page to use the Mitsubishi CNC700/70 series safely.
Details described in this manual:
CAUTION
For items described as "Restrictions" or "Usable State" in this manual, the instruction
manual issued by the machine tool builder takes precedence over this manual. Items that are not described in this manual must be interpreted as "not possible". This manual is written on the assumption that all option functions are added. Confirm the
specifications issued by the machine tool builder before use.
Some screens and functions may differ depending on each NC system (or version), and some
functions may not be possible. Please confirm the specifications before use.
Page 4

Precautions for Safety

Always read the specifications issued by the machine tool builder, this manual, related manuals and attached documents before installation, operation, programming, maintenance or inspection to ensure correct use. Understand this numerical controller , safety items and cautions before using the unit. This manual ranks the safety precautions into "DANGER", "WARNING" and "CAUTION".
DANGER
WARNING
CAUTION
Note that even items ranked as " case, important information that must always be observed is described.
Not applicable in this manual.
When the user may be subject to imminent fatalities or major injuries if handling is mistaken.
When the user may be subject to fatalities or major injuries if handling is mistaken.
When the user may be subject to injuries or when physical damage may occur if handling is mistaken.
CAUTION", may lead to major results depending on the situation. In any
DANGER
W ARNING
Not applicable in this manual.
1. Items related to product and manual
If the descriptions relating to the "restrictions" and "allowable conditions" conflict between this
manual and the machine tool builder's instruction manual‚ the latter has priority over the former.
The operations to which no reference is made in this manual should be considered
impossible.
This manual is complied on the assumption that your machine is provided with all optional
functions. Confirm the functions available for your machine before proceeding to operation by referring to the specification issued by the machine tool builder.
In some NC system versions‚ there may be cases that different pictures appear on the screen‚
the machine operates in a different way on some function is not activated.
CAUTION
Page 5

Contents

1. Outline................................................................................................................................................................ 1
1.1 GUI Library................................................................................................................................................1
2. GDraw ................................................................................................................................................................ 3
2.1 List of GDraw Functions............................................................................................................................3
2.2 Outlines of GDraw Functions....................................................................................................................8
3. GResource.......................................................................................................................................................94
3.1 List of GResource Functions...................................................................................................................94
3.2 Outlines of GResource Functions...........................................................................................................95
4. GEvent............................................................................................................................................................105
4.1 List of GEvent Functions.......................................................................................................................105
4.2 Outline of GEvent Functions.................................................................................................................106
5. GCS ................................................................................................................................................................114
5.1 List of GCS Functions...........................................................................................................................114
5.2 Description of GCS Functions...............................................................................................................131
6. GIO..................................................................................................................................................................413
6.1 List of GIP Functions.............................................................................................................................413
6.2 Outline of GIO Functions.......................................................................................................................414
7. GMMemory.....................................................................................................................................................418
7.1 List of GMMemory Functions................................................................................................................418
7.2 Outline of GMMemory Functions ..........................................................................................................419
Appendix 1. Data Type Definitions..................................................................................................................426
Index.......................................................................................................................... ....................................... X - 1
Page 6

1. Outline

1. Outline
This section gives an outline of the GUI library.

1.1 GUI Library

The GUI library is a C/C++ language GUI library that gives powerful support for GUI development. The GUI library is equipped with the functions necessary for the construction of not only event management but also GUI elements such as window systems, an it support s simple construction of GUIs. In addition, it is equipped with a Graphic Platform Interface (GPI), which is an arrangement for calling up processing dependent on hardware to make porting to various platforms easy. Portin g the GUI library to other platforms is done by creating one with this GPI processing matched to the platform.
User Application
1.1 GUI Library
MethodCall
Event
Event
GEvent
Event/Timer
GResource GDraw
GPI(Grafic Platform Interface)
OS/Driver/Hardware/Font
GUI Library Configuration
GControl
Screen/Frame/
Panel/Window
CallBack
GShape
GWin
1
Page 7
1. Outline
The functions for the various function groups are as follows.
Function Name Outline
GEvent Function group for managing various types of events such as the mouse,
keyboard and timer and window system events such as GWin/GControl/GShape
GResource Function group for handling resources such as character stri ngs, 3D
borders and images GWin Function group for window system management GControl Function group for controlling buttons, pictures and the like that operate
on GWin GShape Function group for managing rectangles, circles, straight lines and other
figures that operate on GWin GDraw Function group for making settings for the drawing environment such as
basic figures, character drawing, coordinates, colors, etc. GPI Function group for handling parts that are dependent on hardware or OS
1.1 GUI Library
2
Page 8

2. GDraw

2.1 List of GDraw Functions

2. GDraw
This section describes the GDraw functions.
2.1 List of GDraw Functions
No. Name Type File name Outline
1 GDBeginDraw void GDBeginDraw.c Begin drawing 2 GDBitBlt void GDBitBlt.c Block transfer 3 GDCalcBorderRect void GDCalcBorderRect.c Calculate rectangular area
based on 3D border settings 4 GDCloseDrawHandle void GDCloseDrawHandle.c Release drawing handle 5 GDDefineFillPattern void GDDefineFillPattern.c Define fill pattern 6 GDDefinePenDash void GDDefinePenDash.c Define line pattern 7 GDDrawArc void GDDrawArc.c Draw arc 8 GDDrawBezier void GDDrawBezier.c Draw Bezier curve 9 GDDrawCaptionCursorStri
ng 10 GDDrawCaptionString void GDDrawCaptionString.c Draw caption character string 11 GDDrawCaptionStringRes
ource 12 GDDrawGrf short GDDrawGrf.c Draw BMP 13 GDDrawImage void GDDrawImage.c Draw image 14 GDDrawImageResource void GDDrawImageResource.c Draw resource image 15 GDDrawOval void GDDrawOval.c Draw oval 16 GDDrawOvalBorder void GDDrawOvalBorder.c Draw (oval) circular 3D border 17 GDDrawOvalBorderResou
rce 18 GDDrawPie void GDDrawPie.c Draw sector 19 GDDrawPoly void GDDrawPoly.c Draw polygon 20 GDDrawRect void GDDrawRect.c Draw rectangle 21 GDDrawRectBorder void GDDrawRectBorder.c Draw rectangular 3D border 22 GDDrawRectBorderResou
rce 23 GDDrawRRect void GDDrawRRect.c Draw roun ded corner rectangle 24 GDDrawString void GDDrawString.c Draw character string 25 GDDrawStringResource void GDDrawStringResource.c Draw resource character string 26 GDEndDraw void GDEndDraw.c End drawing 27 GDFlushScreen void GDFlushScreen.c Refresh screen 28 GDGetCharHeight short GDGetCharHeight.c Get specified character height 29 GDGetCharWidth short GDGetCharWidth.c Get specified character width
void GDDrawCaptionCursorString
.c
void GDDrawCaptionStringResou
rce.c
void GDDrawOvalBorderResourc
e.c
void GDDrawRectBorderResourc
e.c
Draw caption character string (with cursor display)
Draw caption based on character string resources
Draw (oval) circular resource 3D border
Draw rectangular resource 3D border
3
Page 9
2. GDraw
2.1 List of GDraw Functions
No. Name Type File name Outline
30 GDGetNextChar char* GDGetNextChar.c Get next character 31 GDGetPalette void GDGetPalette.c Get palette color code 32 GDGetPixel GColor GDGetPixel.c Get color code for specified
coordinates 33 GDGetPrevChar char* GDGetPrevChar.c Get previous character 34 GDGetStringLength unsigne
d long 35 GDGetStringWidth short GDGetStringWidth.c Get specified character width 36 GDInceptClipRect short GDInceptClipRect.c Clip the area of overlap
37 GDInitPlatform short GDInitPlatform.c Initialization processing for GUI
38 GDLineTo void GDLineTo.c Draw line 39 GDMoveTo void GDMoveTo.c Move pen position 40 GDOffsetLocalOrigin void GDOffsetLocalOrigin.c Offset to local coordinate origin 41 GDOpenDrawHandle HGDRAW GDOpenDrawHandle.c Get drawing handle
GDGetStringLength.c Get character string length
between the specified rectangle and the current clip area
library environment
42 GDQueryError unsigne
d short 43 GDQuitPlatform short GDQuitPlatform.c Quit processing for GUI library
44 GDSetBackColor void GDSetBackColor.c Set background color 45 GDSetBrush void GDSetBrush.c Set brush 46 GDSetClipRect void GDSetClipRect.c Define clipping area 47 GDSetDisplay short GDSetDisplay.c Set graphics mode 48 GDSetDrawingMode void GDSetDrawingMode.c Set raster operations for
49 GDSetFillAttribute void GDSetFillAttribute.c Set fill attributes 50 GDSetFillColor void GDSetFillColor.c Set colors for foreground and
51 GDSetFillPattern void GDSetFillPattern.c Set fill pattern 52 GDSetFont short GDSetFont.c Set font 53 GDSetForeColor void GDSetForeColor.c Set foreground color 54 GDSetLocalMode void GDSetLocalMode.c Set to local (physical)
55 GDSetPenColor void GDSetPenColor.c Set line and character color 56 GDSetPenDash void GDSetPenDash.c Set line pattern 57 GDSetPenJoin void GDSetPenJoin.c Specify joint for rectangles and
58 GDSetPenSize void GDSetPenSize.c Set line width (pen size)
GDQueryError.c Get final error code
environment
drawing
background
coordinate system
polygons
4
Page 10
2. GDraw
2.1 List of GDraw Functions
No. Name Type File name Outline
59 GDSetPixel void GDSetPixel.c Draw pixels 60 GDSetSimpleFont HGFONT GDSetSimpleFont.c Set simple font
61 GDSetSimpleFontResource HGFONT GDSetSimpleFontResource.c Set resource simple font
62 GDSetVirtualMode void GDSetVirtualMode.c Set to virtual coordinate system 63 GDSetVirtualRect void GDSetVirtualRect.c Set rectangular area in virtual
coordinates
64 GDSetVram short GDSetVram.c Set VRAM for drawing
destination 65 GFGetFontAttribute short GFGetFontAttribute.c Get font attributes 66 GFGetFontCount short GFGetFontCount.c Get number of fonts that can be
used 67 GFGetFontInformation short GFGetFontInformation.c Get information for font of
specified No. 68 GFGetFontUserAttribute short GFGetFontUserAttribute.c Get user font attributes 69 GFGetSize short GFGetSize.c Get font size 70 GFLoadFont HGFONT GFLoadFont.c Load specified font
71 GFReleaseFont void GFReleaseFont.c Release font 72 GFSetFontAttribute short GFSetFontAttribute.c Set font attributes 73 GFSetFontUserAttribute short GFSetFontUserAttribute.c Set user font attributes 74 GFSetSize short GFSetSize.c Set character size 75 GRDuplicateRect void GRDuplicateRect.c Copy rectangle 76 GREqualRect short GREqualRect.c Confirm that rectangle areas
are the same 77 GRGetRect void GRGetRect.c Get rectangle area 78 GRInceptRect short GRInceptRect.c Confirm rectangular area
overlap 79 GRMapRect void GRMapRect.c Enlarge/reduce rectangular
area 80 GRMapToScreenRect void GRMapToScreenRect.c Convert rectangular area
defined with pgrRect to screen
coordinate system 81 GRMapToVirtualRect void GRMapToVirtualRect.c Convert rectangular area
defined with pgrRect to virtual
screen coordinate system 82 GROffsetRect void GROffsetRect.c Rectangle offset processing 83 GRPhysicalToVirtualRect void GRPhysicalToVirtualRect.c Convert rectangle physical
coordinates to virtual
coordinates
5
Page 11
2. GDraw
2.1 List of GDraw Functions
No. Name Type File name Outline
84 GRPointInRect short GRPointInRect.c Check if point coordinates fall
within rectangle coordinates 86 GRSetRect void GRSetRect.c Define rectangular area 87 GRShiftRect short GRShiftRect.c Rectangle shift processing 88 GRUnionRect void GRUnionRect.c Join rectangle areas 89 GRVirtualToPhysicalRect void GRVirtualToPhysicalRect.c Convert rectangular area virtual
coordinates to physical
coordinates 90 GLDuplicateLine void GLDuplicateLine.c Copy line structure 91 GLGetLine void GLGetLine.c Get line 92 GLMapLine void GLMapLine.c Enlarge/reduce line
coordinates 93 GLOffsetLine void GLOffsetLine.c Offset processing for line
structure 94 GLPhysicalToVirtualLine void GLPhysicalToVirtualLine.c Convert line structure physical
coordinates to virtual
coordinates 95 GLSetLine void GLSetLine.c Define line structure 96 GLVirtualToPhysicalLine void GLVirtualToPhysicalLine.c Convert line structure virtual
coordinates to physical
coordinates 97 GPTDuplicatePoint void GPTDuplicatePoint.c Copy point structure 98 GPTGetPoint void GPTGetPoint.c Get point structure content 99 GPTMapPoint void GPTMapPoint.c Map rectangle defined with
pgrFrom to rectangle defined
with pgrTo
100 GPTMapToScreenPoint void GPTMapToScreenPoint.c Convert point structure to
screen coordinates
101 GPTMapToVirtualPoint void GPTMapToVirtualPoint.c Convert point defined in
pgptPoint to virtual screen
coordinate system
102 GPTOffsetPoint void GPTOffsetPoint.c Point structure offset
processing
103 GPTPhysicalToVirtualPoint void GPTPhysicalToVirtualPoint.c Convert point structure physical
coordinates to virtual
coordinates
104 GPTSetPoint void GPTSetPoint.c Define point structure 105 GPTVirtualToPhysicalPoint void GPTVirtualToPhysicalPoint.c Convert point structure virtual
coordinates to physical
coordinates
106 GPGetPoly void GPGetPoly.c Get polygon settings 107 GPMapPoly void GPMapPoly.c Enlarge/reduce polygon
6
Page 12
2. GDraw
2.1 List of GDraw Functions
No. Name Type File name Outline 108 GPOffsetPoly void GPOffsetPoly.c Polygon offset processing 109 GPPhysicalToVirtualPoly void GPPhysicalToVirtualPoly.c Convert polygon physical
coordinates to virtual
coordinates
112 GMSetMemorySpace short GMemory.c Register memory area
information
113 GMDeleteMemorySpace short GMemory.c Delete regi stered memory area 114 GMMemoryAlloc void* GMemory.c Allocate memory area 115 GMMemoryFree short GMemory.c Release memory are a 116 GDCreateVram HGVRAM GDCreateVram.c Create virtual VRAM
117 GDDeleteVram void GDDeleteVram.c Release virtual VRAM 118 GDFlushScreenForce void GDFlushScreenForce.c Forcible refresh screen 119 GDGetGradationInfo void GDGetGradationInfo.c Get gradation information 120 GDGetLocalOrigin void GDGetLocalOrigin.c Get local coordinate origin 121 GDGetVram HGVRAM GDGetVram.c Get system VRAM
122 GDRemoveDrawableRegi
on 123 GDSetDrawableRegion short GDSetDrawableRegion.c Set drawable area 124 GDSetGradationInfo void GDSetGradationInfo.c Set gradation information 125 GDSetLocalOrigin void GDSetLocalOrigin.c Set local coordinate origin
short GDRemoveDrawableRegion.c Delete rectangular area from
drawable area
7
Page 13
2. GDraw

2.2 Outlines of GDraw Functions

GDBeginDraw
GDBeginDraw.c Outline Begin drawing
Syntax void GDBeginDraw( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : draw handle
Return value None
Details
File name GDBeginDraw.c
This must be called just once when drawing on the screen for drawing basic figures, displaying image data and the like.
2.2 Descriptions of GDraw Functions
8
Page 14
2. GDraw
GDBitBlt
GDBitBlt.c Outline Block transfer
Syntax void GDBitBlt( HGDRAW hDraw, HGVRAM hSrc, short nSrcX, short nSrcY, short nWidth, short nHeight, HGVRAM hDest, short nDestX, short nDestY, short nDrawingMode )
Argument (i/o) HGDRAW hDraw : drawing handle (i) HGVRAM hSrc : source VRAM handle (i) short nSrcX : source X coordinate (i) short nSrcY : source Y coordinate (i) short nWidth : transmission area width (i) short nHeight : transmission area height (i) HGVRAM hDest : destination VRAM handle (i) nDestX : destination X coordinate (i) nDestY : destination Y coordinate (i) nDrawingMode : raster operation
Return value None
Details
File name GDBitBlt.c
2.2 Descriptions of GDraw Functions
Transfers the nWidth*nHeight sized area based on the specified point (nSrcX, nSrcY) in the VRAM of the transmission source (hSrc) to the nWidth*nHeight sized area based on another specified point (nDestX, nDestY) in the transmission destination (hDest). The transfer method depends on nDrawingMode. Corresponds to physical coordinates BitBlt only, and not virtual coordinates.
9
Page 15
2. GDraw
GDCalcBorderRect
GDCalcBorderRect.c Outline Calculate rectangular area based on 3D border settings
Syntax void GDCalcBorderRect( GRect *pBounds, GRect *pInside, GRect *pBorderRect, GBorder *pBorder )
Argument (i) GRect *pBounds : perimeter rectangle area (o) GRect *pInside : rectangle area inside 3D border (o) GRect *pBorderRect : 3D border area (i) GBorder *pBorder : 3D border
Return value None
Details
File name GDCalcBorderRect.c
2.2 Descriptions of GDraw Functions
Calculates the position of the rectangle when a 3D border is drawn within pBounds based on the pBorder settings. The rectangular area within the 3D border is stored in plnside. The perimeter rectangle for the 3D border is stored in pBorderRect .
GDCloseDrawHandle
GDCloseDrawHandle.c Outline Release drawing handle
Syntax void GDCloseDrawHandle( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle to be released
Return value None
Details The drawing handle is released.
File name GDCloseDrawHandle.c
10
Page 16
2. GDraw
GDDefineFillPattern
GDDefineFillPattern.c Outline Define fill pattern
Syntax void GDDefineFillPattern( HGDRAW hDraw, short nFillPattern, char *pcPattern )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nFillPattern : fill pattern specification (i) char *pcPattern : fill pattern definition
Return value None
Details
File name GDDefineFillPattern.c
2.2 Descriptions of GDraw Functions
Set pcPattern in nFillPattern No. fill pattern. When a pattern No. outside of the range is set, GERROR_BAD_PATTERN_NUM is set as the error.
11
Page 17
2. GDraw
GDDefinePenDash
GDDefinePenDash.c Outline Define line pattern
Syntax void GDDefinePenDash( HGDRAW hDraw, short nPenDash, char *pcDash )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nPenDash : line pattern No. specification (i) char *pcDash : line pattern
Return value None
Details Set pcDash in nPenDash No. line pattern. Since nPenDash number 0 is set to solid line, specify 1 or higher.
File name GDDefinePenDash.c
2.2 Descriptions of GDraw Functions
12
Page 18
2. GDraw
GDDrawArc
GDDrawArc.c Outline Draw arc
Syntax void GDDrawArc( HGDRAW hDraw, GRect *pgrRect, short nStartAngle, short nEndAngle )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangle area (i) short nStartAngle : 10 times of the starting angle (i) short nEndAngle : 10 times of the ending angle
Return value None
Details Draws an arc in contact with the inside of the rectangle defined with pgrRect. The starting angle is nStartAngle, and the ending angle is nEndAngle. Line color, line type, line thickness and raster operation are enabled as drawing
File name GDDrawArc.c
attributes.
2.2 Descriptions of GDraw Functions
13
Page 19
2. GDraw
GDDrawBezier
GDDrawBezier.c Outline Draw Bezier curve
Syntax void GDDrawBezier( HGDRAW hDraw, GPoly *pgpPoly )
Argument (i/o) HGDRAW hDraw : drawing han dle (i) GPoly *pgpPoly : polygon structure
Return value None
Details
File name GDDrawBezier.c
2.2 Descriptions of GDraw Functions
Draws a Bezier curve joining the points defined with pgpPoly. Line color, line type, line thickness and raster operation are enabled as drawing attributes.
14
Page 20
2. GDraw
GDDrawCaptionCursorString
GDDrawCaptionCursorString.c Outline Draw caption character string (with cursor display)
Syntax void GDDrawCaptionCursorString( HGDRAW hDraw, GRect *pBounds, GCaption * pCaption, GCursor *pCursor, long lCursorPos, char *pString )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GCaption *pCaption : caption information (i/o) GCursor *pCursor : data with cursor displayed (i) long lCursorPos : character cursor display position (i) char *pString : character string
Return value None
Details
File name GDDrawCaptionCursorString.c
2.2 Descriptions of GDraw Functions
pString character string is drawn with the cursor displayed according to the pCaption settings so that it fills the pBounds rectangular area.
15
Page 21
2. GDraw
GDDrawCaptionString
GDDrawCaptionString.c Outline Draw caption character string
Syntax void GDDrawCaptionString( HGDRAW hDraw, GRect *pBounds, GCaption *pCaption, char *pString )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GCaption *pCaption : caption information (i) char *pString : character string
Return value None
Details
File name GDDrawCaptionString.c
2.2 Descriptions of GDraw Functions
pString character string is drawn according to the pCaption settings so that it fills the pBounds rectangular area.
16
Page 22
2. GDraw
GDDrawCaptionStringResource
GDDrawCaptionStringResource.c Outline Draw caption based on character string resources
Syntax void GDDrawCaptionStringResource( HGDRAW hDraw, GRect *pBounds, GCaption *pCaption, unsigned short usResourceID )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GCaption *pCaption : caption information (i) unsigned short usResourceID : character string resource ID
Return value None
Details
File name GDDrawCaptionStringResource.c
2.2 Descriptions of GDraw Functions
usResourceID resource character string is drawn according to the pCaption settings so that it fills the pBounds rectangular area.
17
Page 23
2. GDraw
2.2 Descriptions of GDraw Functions
GDDrawGrf
GDDrawGrf.c Outline Draw BMP
Syntax short GDDrawGrf( HGDRAW hDraw, GRFHeader *pGHeader, unsigned char *pData, short nX, short nY, short nWidth, short nHeight )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRFHeader *pGHeader : BMP information structure (i) unsigned char *pData : BMP data (i) short nX : coordinates for starting drawing
(upper left of BMP)
(i) short nY : coordinates for starting drawing
(upper left of BMP) (i) short nWidth : display all when drawing area size is 0 or lower (i) short nHeight : display all when drawing area size is 0 or lower
Return value FALSE : drawing failed TRUE : drawing succeeded
Details
File name GDDrawGrf.c
The pData image having pGHeader information is drawn in the size of nWidth*nHeight starting at (nX,nY). When 0 is specified for nWidth, it is displayed in the size of the image. When 0 is specified for nHeight, it is displayed in the size of the image.
18
Page 24
2. GDraw
2.2 Descriptions of GDraw Functions
GDDrawImage
GDDrawImage.c Outline Draw image
Syntax void GDDrawImage( HGDRAW hDraw, GImage *pImage, short nX, short nY, short nWidth, shor nHeight )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GImage *pImage : image (i) short nX : drawing start position (x coordinate) (i) short nY : drawing start position (y coordinate) (i) short nWidth : drawing area width (i) short nHeight : drawing area height
Return value None
Details
File name GDDrawImage.c
Draws the GImage image in the size of nWidth*nHeight starting at (nX, nY). GImage contains the data for any of the images that are supported in the GUI library as standard format data, and the processing function is called according to the type of image. At present this is only Graphic Raster Format (GRF)
19
Page 25
2. GDraw
GDDrawImageResource
GDDrawImageResource.c Outline Draw resource image
Syntax void GDDrawImageResource( HGDRAW hDraw, unsigned short usResourceID, short nX, short nY, short nWidth, short nHeight )
Argument (i/o) HGDRAW hDraw : drawing handle (i) usResourceID : image resource ID (i) short nX : drawing start position (X coordinate) (i) short nY : drawing start position (Y coordinate) (i) short nWidth : drawing area width (i) short nHeight : drawing area height
Return value None
Details
File name GDDrawImageResource.c
2.2 Descriptions of GDraw Functions
Draws the usResourceID resource image in the size of nWidth*nHeight starting at (nX, nY).
20
Page 26
2. GDraw
GDDrawOval
GDDrawOval.c Outline Draw oval
Syntax void GDDrawOval( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangle area
Return value None
Details
File name GDDrawOval.c
2.2 Descriptions of GDraw Functions
Draws an (oval) circle in contact with the inside of the rectangle defined with pgrRect. For the fill inside the shape, the fill pattern, foreground color and background color, and for the perimeter, line color, line thickness, line type and raster operation are enabled as drawing attributes.
21
Page 27
2. GDraw
GDDrawOvalBorder
GDDrawOvalBorder.c Outline Draw (oval) circular 3D border
Syntax void GDDrawOvalBorder( HGDRAW hDraw, GRect *pBounds, GRect *pInside, GBorder *pBorder, short nStatus )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GRect *pInside : rectangle in contact inside (i) GBorder *pBorder : 3D border (i) short nStatus : status FALSE : convex status TRUE : concave status
Return value None
Details
File name GDDrawOvalBorder.c
2.2 Descriptions of GDraw Functions
Draws the 3D border in pBorder in an (oval) circle shape in the size of the rectangle in contact with the inside of the rectangular area in pBo unds. When, in this instance, nStatus is FALSE, filling of the upper left and lower right borders i s done with the colors that have been set, but if it is TRUE, the colors for filling of the upper left and lower right borders is reversed.
22
Page 28
2. GDraw
GDDrawOvalBorderResource
GDDrawOvalBorderResource.c Outline Draw (oval) circular resource 3D border
Syntax void GDDrawOvalBorderResource( HGDRAW hDraw, GRect *pBounds, GRect *pInside, unsigned short usResourceID, short nStatus )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GRect *pInside : rectangle in contact inside (i) unsigned short usResourceID : 3D border resource ID (i) short nStatus : status FALSE : convex status TRUE : concave status
Return value None
Details
File name GDDrawOvalBorderResource.c
2.2 Descriptions of GDraw Functions
Draws the 3D border in usResourceID in an (oval) circle shape in the size of the rectangle in contact with the inside of the rectangular area in pBo unds. When, in this instance, nStatus is FALSE, filling of the upper left and lower right borders i s done with the colors that have been set, but if it is TRUE, the colors for filling of the upper left and lower right borders is reversed.
23
Page 29
2. GDraw
GDDrawPie
GDDrawPie.c Outline Draw sector
Syntax void GDDrawPie( HGDRAW hDraw, GRect *pgrRect, short nStartAngle, short nEndAngle )
Argument (i/o) HGDRAW hDraw : drawing han dle (i) GRect *pgrRect : rectangle area (i) short nStartAngle : 10 times of the starting angle (i) short nEndAngle : 10 times of the ending angle
Return value None
Details
File name GDDrawPie.c
2.2 Descriptions of GDraw Functions
Draws a sector in contact with the inside of the rectangle defined with pgrRe ct. The starting angle is nStartAngle, and the ending angle is nEndAngle. For the fill inside the shape, the fill pattern, foreground color and background color, and for the perimeter, line color, line thickness, line type and raster operation are enabled as drawing attributes.
24
Page 30
2. GDraw
GDDrawPoly
GDDrawPoly.c Outline Draw polygon
Syntax void GDDrawPoly( HGDRAW hDraw, GPoly *pgpPoly )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GPoly *pgpPoly : polygon structure
Return value None
Details
File name GDDrawPoly.c
2.2 Descriptions of GDraw Functions
Draws the polygon defined in pgpPoly. For the fill inside the shape, the fill pattern, foreground color and background color, and for the perimeter, line color, line thickness, line type and raster operation are enabled as drawing attributes.
GDDrawRect
GDDrawRect.c Outline Draw rectangle
Syntax void GDDrawRect( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangle area
Return value None
Details
File name GDDrawRect.c
Draws the rectangle in the rectangular area defined in pgrRect. For the fill inside the shape, the fill pattern, foreground color and background color, and for the perimeter, line color, line thickness, line type and raster operation are enabled as drawing attributes.
25
Page 31
2. GDraw
GDDrawRectBorder
GDDrawRectBorder.c Outline Draw rectangular 3D border
Syntax void GDDrawRectBorder( HGDRAW hDraw, GRect *pBounds, GRect *pInside, GBorder *pBorder, short nStatus )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GRect *pInside : rectangle in contact inside (i) GBorder *pBorder : 3D border (i) short nStatus : status FALSE : convex status TRUE : concave status
Return value None
Details
File name GDDrawRectBorder.c
2.2 Descriptions of GDraw Functions
Draws a 3D border in pBorder in an rectangle in the size of the rectangle in contact with the inside of the rectangular area in pBounds. When, in this instance, nStatus is FALSE, filling of the upper left and lower right borders is done with the colors that have been set, but if it is TRUE, the colors for filling of the upper left and lower right borders is reversed.
26
Page 32
2. GDraw
GDDrawRectBorderResource
GDDrawRectBorderResource.c Outline Draw resource rectangular 3D border
Syntax void GDDrawRectBorderResource( HGDRAW hDraw, GRect *pBounds, GRect *pInside, unsigned short usResourceID, short nStatus )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pBounds : rectangle area (i) GRect *pInside : rectangle in contact inside (i) unsigned short usResourceID : 3D border (i) short nStatus : status FALSE : convex status TRUE : concave status
Return value None
Details
File name GDDrawRectBorderResource.c
2.2 Descriptions of GDraw Functions
Draws a border in usResourceID in a rectangle in the size of the rectangle in contact with the inside of the rectangular area in pBounds. When, in this instance, nStatus is FALSE, filling of the upper left and lower right borders is done with the colors that have been set, but if it is TRUE, the colors for filling of the upper left and lower right borders is reversed.
27
Page 33
2. GDraw
GDDrawRRect
GDDrawRRect.c Outline Draw rounded corner rectangle
Syntax void GDDrawRRect( HGDRAW hDraw, GRect *pgrRect, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangle area (i) short nX : X axis of corner a rc (i) short nY : Y axis of corner a rc
Return value None
Details
File name GDDrawRRect.c
2.2 Descriptions of GDraw Functions
Draws the rounded corner rectangle in the rectangular area define d in pgrRect. The rounding of the corners is defined with nX and nY. For the fill inside the shape, the fill pattern, foreground color and background color, and for the perimeter, line color, line thickness, line type and raster operation are enabled as drawing attributes.
28
Page 34
2. GDraw
GDDrawString
GDDrawString.c Outline Draw character string
Syntax void GDDrawString( HGDRAW hDraw, char *pszString )
Argument (i/o) HGDRAW hDraw : drawing handle (i) char *pszString : draw character string
Return value None
Details
File name GDDrawString.c
2.2 Descriptions of GDraw Functions
Draws the pszString character string starting at the current pen position. Pen color, background color and text mode are enabled as the drawing attributes.
GDDrawStringResource
GDDrawStringResource.c Outline Draw resource character string
Syntax void GDDrawStringResource( HGDRAW hDraw, unsigned short usResourceID )
Argument (i/o) HGDRAW hDraw : drawing handle (i) unsigned short usResourceID : draw resource character string
Return value None
Details
Pen color, background color and text mode are enabled as the drawing
File name GDDrawStringResource.c
Draws the usResourceID resource character string starting at the current pen position.
attributes.
29
Page 35
2. GDraw
GDEndDraw
GDEndDraw.c Outline End drawing
Syntax void GDEndDraw( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle
Return value None
Details
File name GDEndDraw.c
2.2 Descriptions of GDraw Functions
Quits screen drawing. This is called after drawing on the screen for basic figure drawing, data display and the like.
GDFlushScreen
GDFlushScreen.c Outline Refresh screen
Syntax void GDFlushScreen( HGDRAW hDraw, short nX, short nY, short nWidth, short nHeight )
Argument (i/o) HGDRAW hDraw : drawing han dle (i) short nX : X coordinate for drawing starting point (i) short nY : Y coordinate for drawing starting point (i) short nWidth : drawing width (i) short nHeight : drawing height
Return value None
Details
File name GDFlushScreen.c
A screen for the size of nWidth*nHeight is refreshed in the current coordinate system with (nX, nY) as the starting point.
30
Page 36
2. GDraw
GDGetCharHeight
GDGetCharHeight.c Outline Get specified character height
Syntax short GDGetCharHeight( HGDRAW hDraw, short nCharCode )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nCharCode : character code
Return value Character height
Details Get specified character height with current font settings.
File name GDGetCharHeight.c
2.2 Descriptions of GDraw Functions
GDGetCharWidth
GDGetCharWidth.c Outline Get specified character width
Syntax short GDGetCharWidth( HGDRAW hDraw, short nCharCode )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nCharCode : character code
Return value Character width
Details Get specified character width with current font settings.
File name GDGetCharWidth.c
31
Page 37
2. GDraw
GDGetNextChar
GDGetNextChar.c Outline Get next character
Syntax char* GDGetNextChar( HGDRAW hDraw, char *pszString, char *pszNow )
Argument (i/o) HGDRAW hDraw : drawing handle (i) char *pszString : character string (i) char *pszNow : character position - starting point for the next
Return value Pointer to the next character of the specified character
Details
File name GDGetNextChar.c
2.2 Descriptions of GDraw Functions
character search
Searches for the next character using the specified character in the specified character string as the starting point.
32
Page 38
2. GDraw
GDGetPalette
GDGetPalette.c Outline Get palette color code
Syntax void GDGetPalette( HGDRAW hDraw, short nStart, short nCount, GColor *pgcColorArray )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nStart : starting No. to get (i) short nCount : number of colors to get (o) GColor *pgcColorArray : array storing color code
Return value None
Details
File name GDGetPalette.c
2.2 Descriptions of GDraw Functions
nCount color codes starting at nStart in the color pallet are acquired in pgcColorArray.
33
Page 39
2. GDraw
GDGetPixel
GDGetPixel.c Outline Get color code for specified coordinates
Syntax GColor GDGetPixel( HGDRAW hDraw, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : X coordinate (i) short nY : Y coordinate
Return value Color code
Details Gets the color code for (nX, nY). The color code depends on the current color environment.
File name GDGetPixel.c
2.2 Descriptions of GDraw Functions
34
Page 40
2. GDraw
GDGetPrevChar
GDGetPrevChar.c Outline Get previous character
Syntax char* GDGetPrevChar( HGDRAW hDraw, char * pszString, char * pszNow )
Argument (i/o) HGDRAW hDraw : drawing handle (i) char *pszString : character string (i) char *pszNow : character position - starting point for the previous
Character position
Return value Pointer to the previous character of the specified character
Details
File name GDGetPrevChar.c
2.2 Descriptions of GDraw Functions
character search
Searches for the previous character using the specified character in the specified character string as the starting point.
GDGetStringLength
GDGetStringLength.c Outline Get character length
Syntax unsigned long GDGetStringLength( HGDRAW hDraw, char *pszString )
Argument (i/o) HGDRAW hDraw : drawing handle (i) char *pszString : character string in which the characters are to be
counted
Return value Number of characters
Details Gets the number of characters in the specified character string.
File name GDGetStringLength.c
35
Page 41
2. GDraw
GDGetStringWidth
GDGetStringWidth.c Outline Get specified character width
Syntax short GDGetStringWidth( HGDRAW hDraw, char *pszString )
Argument (i/o) HGDRAW hDraw : drawing handle (i) char *pszString : character string
Return value Character string width
Details Gets the width of a character string specified by pszString.
File name GDGetStringWidth.c
2.2 Descriptions of GDraw Functions
36
Page 42
2. GDraw
GDInceptClipRect
GDInceptClipRect.c Outline
Syntax short GDInceptClipRect( HGDRAW hDraw, GRect *pgrClip, GRect *pOldClip )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrClip : rectangle area (o) GRect *pOldClip : clip area before change
Return value FALSE : clipping failed TRUE : clipping succeeded
Details
File name GDInceptClipRect.c
GDInitPlatform
2.2 Descriptions of GDraw Functions
Clip the area of overlap between the specified rectangle and the current clip area
Defines the portion of overlap between the pgrClip rectangular area displaying characters or graphics on the screen and the current clip area. The clip area up to that point is stored in pOldClip. Either physical or virtual coordinates can be used for the clip area, and the setting is applied to the coordinate system at the time this function is called.
GDInitPlatform.c Outline Carrying out initialization processing for GUI library environment
Syntax short GDInitPlatform( void *pParameter )
Argument (i) void* pParameter : additional platform information
Return value FALSE : initialization failed TRUE : initialization succeeded
Details Initializes the platform that uses the GUI library.
File name GDInitPlatform.c
37
Page 43
2. GDraw
GDLineTo
GDLineTo.c Outline Draw line
Syntax void GDLineTo( HGDRAW hDraw, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : X coordinate (i) short nY : Y coordinate
Return value None
Details Draws a line from the current pen position to (nX, nY).
File name GDLineTo.c
2.2 Descriptions of GDraw Functions
GDMoveTo
GDMoveTo.c Outline Move pen position
Syntax void GDMoveTo( HGDRAW hDraw, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : X coordinate (i) short nY : Y coordinate
Return value None
Details Moves pen position to (nX, nY).
File name GDMoveTo.c
38
Page 44
2. GDraw
GDOffsetLocalOrigin
GDOffsetLocalOrigin.c Outline Offset to local coordinate origin
Syntax void GDOffsetLocalOrigin( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GPoint *pgptPoint : point structure
Return value None
Details
File name GDOffsetLocalOrigin.c
2.2 Descriptions of GDraw Functions
An offset of pgptPoint.nX in the X direction and pgptPoint.nY in the Y direction is applied to the origin for the local (physical) coordinates.
GDOpenDrawHandle
GDOpenDrawHandle.c Outline Get drawing handle
Syntax HGDRAW GDOpenDrawHandle( short nType, void *pParameter )
Argument (i) short nType : display mode (i) void *pParameter : additional handle information
Return value NULL : acquisition failed Other than NULL : drawing handle
Details Gets the drawing handle.
File name GDOpenDrawHandle.c
39
Page 45
2. GDraw
GDQueryError
GDQueryError.c Outline Get final error code
Syntax unsigned short GDQueryError( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle
Return value Error No.
Details The final error code within the GUI library is acquired.
File name GDQueryError.c
2.2 Descriptions of GDraw Functions
GDQuitPlatform
GDQuitPlatform.c Outline Quit processing for GUI library environment
Syntax short GDQuitPlatform()
Argument None
Return value FALSE : failed TRUE : succeeded
Details
File name GDQuitPlatform.c
Carries out end processing for the platform environment used by the GUI library.
40
Page 46
2. GDraw
GDSetBackColor
GDSetBackColor.c Outline Set background color
Syntax void GDSetBackColor( HGDRAW hDraw, GColor gcBackColor )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GColor gcBackColor : background color to be set
Return value None
Details
NO_DRAW : no background fill Color code : fill background using specified color code
File name GDSetBackColor.c
2.2 Descriptions of GDraw Functions
Sets the background color. When NO_DRAW is set for the background color, the background color pixels are not filled in during drawing.
GDSetBrush
GDSetBrush.c Outline Set brush
Syntax void GDSetBrush( HGDRAW hDraw, GBrush *pBrush )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GBrush *pBrush : brush being set
Return value None
Details
File name GDSetBrush.c
The brush to be used is set as a fill attribute. The brush set is registered as a fill pattern, foreground color and background color setting.
41
Page 47
2. GDraw
GDSetClipRect
GDSetClipRect Outline Define clipping area
Syntax void GDSetClipRect( HGDRAW hDraw, GRect *pgrClip )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrClip : rectangle area
Return value None
Details
File name GDSetClipRect.c
2.2 Descriptions of GDraw Functions
A rectangular area for displaying characters or graphics on the screen is set as pgrClip. Either physical or virtual coordinates can be used for the clip area, and the setting is applied to the coordinate system at the time this function is called.
GDSetDisplay
GDSetDisplay.c Outline Set graphics mode
Syntax short GDSetDisplay( HGDRAW hDraw, short nType )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nType : graphics mode to be set
Return value FALSE : setting failed TRUE : setting succeeded
Details
File name GDSetDisplay.c
Sets the graphics mode. The mode depends on the platform, so it is not defined as the GUI library.
42
Page 48
2. GDraw
GDSetDrawingMode
GDSetDrawingMode.c Outline Set raster operations for drawing
Syntax void GDSetDrawingMode( HGDRAW hDraw, short nMode )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nMode : raster operation
Return value None
Details Sets the raster operation for drawing. GRASTER_OPERATION_REPLACE : overwrite GRASTER_OPERATION_AND : AND with base GRASTER_OPERATION_OR : OR with base GRASTER_OPERATION_XOR : XOR with base
File name GDSetDrawingMode.c
2.2 Descriptions of GDraw Functions
43
Page 49
2. GDraw
GDSetFillAttribute
GDSetFillAttribute.c Outline Set fill attributes
Syntax void GDSetFillAttribute( HGDRAW hDraw, short nPattern, GColor gcForeColor, GColor gcBackColor )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nPattern : fill pattern (i) GColor gcForeColor : foreground color (i) GColor gcBackColor : background color
Return value None
Details Sets the fill attributes. nPattern NO_DRAW : no fill FILL_FORE_COLOR : fill with single foreground color FILL_BACK_COLOR : fill with single background color 0 to 37 : fill using pattern for specified No. gcForeColor NO_DRAW : no foreground fill Color code : fill foreground using specified color code gcBackColor NO_DRAW : no background fill Color code : fill background using specified color code
File name GDSetFillAttribute.c
2.2 Descriptions of GDraw Functions
44
Page 50
2. GDraw
GDSetFillColor
GDSetFillColor.c Outline Set colors for foreground and background
Syntax void GDSetFillColor( HGDRAW hDraw, GColor gcForeColor, GColor gcBackColor )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GColor gcForeColort : foreground color to be se (i) GColor gcBackColor : background color to be set
Return value None
Details Sets the foreground color and background color. gcForeColor NO_DRAW : no foreground fill Color code : fill foreground using specified color code gcBackColor NO_DRAW : no background fill Color code : fill background using specified color code
File name GDSetFillColor.c
2.2 Descriptions of GDraw Functions
45
Page 51
2. GDraw
GDSetFillPattern
GDSetFillPattern.c Outline Set fill pattern
Syntax void GDSetFillPattern( HGDRAW hDraw, short nPattern )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nPattern : fill pattern
Return value None
Details Sets the fill pattern. nPattern NO_DRAW : no fill FILL_FORE_COLOR : fill with single foreground color FILL_BACK_COLOR : fill with single background color 0 to 37 : fill using pattern for specified No.
File name GDSetFillPattern.c
2.2 Descriptions of GDraw Functions
46
Page 52
2. GDraw
GDSetFont
GDSetFont.c Outline Set font
Syntax short GDSetFont( HGDRAW hDraw, HGFONT hFont )
Argument (i/o) HGDRAW hDraw : drawing handle (i) HGFONT hFont : font handle
Return value FALSE : setting failed TRUE : setting succeeded
Details Set the hFont font as the font for character drawing.
File name GDSetFont.c
2.2 Descriptions of GDraw Functions
GDSetForeColor
GDSetForeColor.c Outline Set foreground color
Syntax void GDSetForeColor( HGDRAW hDraw, GColor gcForeColor )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GColor gcForeColor : foreground color to be set
Return value None
Details Sets the foreground color. gcForeColor NO_DRAW : no foreground fill Color code : fill foreground using specified color code
File name GDSetForeColor.c
47
Page 53
2. GDraw
GDSetLocalMode
GDSetLocalMode.c Outline Set to local (physical) coordinate system
Syntax void GDSetLocalMode( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle
Return value None
Details
File name GDSetLocalMode.c
2.2 Descriptions of GDraw Functions
Sets the coordinate system to local (physical) coordinates. After the coordinate system is set to local coordinates, all GUI library functions are executed using the local (physical) coordinates system.
GDSetPenColor
GDSetPenColor.c Outline Set line and character color
Syntax void GDSetPenColor( HGDRAW hDraw, GColor gcPenColor )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GColor gcPenColor : color to be set for lines/characters
Return value None
Details Sets the color for lines and characters. gcPenColor NO_DRAW : no drawing Color code : draw lines and characters using the specified color code
File name GDSetPenColor.c
48
Page 54
2. GDraw
GDSetPenDash
GDSetPenDash.c Outline Set line pattern
Syntax void GDSetPenDash( HGDRAW hDraw, short nDash )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nDash : line pattern
Return value None
Details Specifies the line pattern to use when drawing lines. nDash 0 : solid line 1 to 8 : defined line pattern
File name GDSetPenDash.c
2.2 Descriptions of GDraw Functions
49
Page 55
2. GDraw
GDSetPenJoin
GDSetPenJoin.c Outline Specify joint for rectangles and polygons + D968
Syntax void GDSetPenJoin( HGDRAW hDraw, short nJoin )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nJoin : type of joint
Return value None
Details Specifies the joint for rectangle and polygon perimeters. nJoin NONE : none BEVEL : line ROUND : rounded corners
File name GDSetPenJoin.c
2.2 Descriptions of GDraw Functions
50
Page 56
2. GDraw
GDSetPenSize
GDSetPenSize.c Outline Set line width (pen size)
Syntax void GDSetPenSize( HGDRAW hDraw, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : thickness in X direction (i) short nY : thickness in Y direction
Return value None
Details Sets the thickness of lines and perimeter lines. nX is the horizontal thickness, and nY is the vertical thickness.
File name GDSetPenSize.c
2.2 Descriptions of GDraw Functions
GDSetPixel
GDSetPixel.c Outline Draw pixels
Syntax void GDSetPixel( HGDRAW hDraw, short nX, short nY )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : X coordinate (i) short nY : Y coordinate
Return value None
Details Draws a point in the specified (nX, nY) coordinates. After point drawing, the current position changes to the specified position.
File name GDSetPixel.c
51
Page 57
2. GDraw
GDSetSimpleFont
GDSetSimpleFont.c Outline Set simple font
Syntax HGFONT GDSetSimpleFont( HGDRAW hDraw, GSimpleFont *pFont )
Argument (i/o) HGDRAW hDraw : drawing handle (i)GSimpleFont *pFont : set simple font
Return value Font handle set
Details Changes the current font to a simple font pFont.
File name GDSetSimpleFont.c
2.2 Descriptions of GDraw Functions
GDSetSimpleFontResource
GDSetSimpleFontResource.c Outline Set resource simple font
Syntax HGFONT GDSetSimpleFontResource( HGDRAW hDraw, unsigned short usResourceID )
Argument (i/o) HGDRAW hDraw : drawing handle (i) unsigned short usResourceID : set simple font
Return value Font handle set
Details Changes the current font to a resource simple font usResourceID.
File name GDSetSimpleFontResource.c
52
Page 58
2. GDraw
GDSetVirtualMode
GDSetVirtualMode.c Outline Set to virtual coordinate system
Syntax void GDSetVirtualMode( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle
Return value None
Details The coordinate system is set to the virtual coordinate system. After the coordinate system is set to the virtual coordinate system, all GUI
File name GDSetVirtualMode.c
2.2 Descriptions of GDraw Functions
library functions are executed using the virtual coordinate system.
GDSetVirtualRect
GDSetVirtualRect.c Outline Set rectangular area in virtual coordinates
Syntax void GDSetVirtualRect( HGDRAW hDraw, GRect *pgrVirtual )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrVirtual : virtual coordinate rectangle area
Return value None
Details The rectangular area for the virtual coordinate system is set in pgrVirtual.
File name GDSetVirtualRect.c
53
Page 59
2. GDraw
GDSetVram
GDSetVram.c Outline Set VRAM for drawing destination
Syntax short GDSetVram( HGDRAW hDraw, short nType, HGVRAM hVram )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nType DEFAULT_SCREEN : set actual VRAM for drawing destination MEMORY_SCREEN : set v irtual VRAM for drawing destination (i) HGVRAM hVram : VRAM handle when specifying virtual VRAM
Return value FALSE : failed TRUE : succeeded
Details The drawing destination VRAM is specified in hVram.
File name GDSetVram.c
2.2 Descriptions of GDraw Functions
GFGetFontAttribute
GFGetFontAttribute.c Outline Get font attributes
Syntax short GFGetFontAttribute( HGFONT hFont, GFontAttribute *pgfaAttribute )
Argument (i) HGFONT hFont : font (o) GFontattribute *pgfaAttribute : attribute
Return value FALSE : failed TRUE : succeeded
Details Gets the attributes for the font handle font.
File name GFGetFontAttribute.c
54
Page 60
2. GDraw
GFGetFontCount
GFGetFontCount.c Outline Get number of fonts that can be used
Syntax short GFGetFontCount()
Argument None
Return value Number of fonts
Details This is supported by the current platform. Gets fonts.
File name GFGetFontCount.c
2.2 Descriptions of GDraw Functions
GFGetFontInformation
GFGetFontInformation.c Outline Get font information for the specified number
Syntax short GFGetFontInformation( short nIndex, GFont **pgfFont )
Argument (i) short nIndex : font No. (o) GFont **pgfFont : font information
Return value FALSE : failed TRUE : succeeded
Details This is supported by the platform. Gets the font information for the specified font No.
File name GFGetFontInformation.c
55
Page 61
2. GDraw
GFGetFontUserAttribute
GFGetFontUserAttribute.c Outline Get user font attributes
Syntax short GFGetFontUserAttribute( HGFONT hFont, short *pnAttributeArray )
Argument (i) HGFONT hFont : font (o) short *pnAttributeArray : attribute unique to platform
Return value FALSE : failed TRUE : succeeded
Details Gets the font attributes peculiar to the font handle.
File name GFGetFontUserAttribute.c
2.2 Descriptions of GDraw Functions
GFGetSize
GFGetSize.c Outline Get font size
Syntax short GFGetSize( HGFONT hFont, short *nWidth, short *nHeight )
Argument (i) HGFONT hFont : font (o) short *nWidth : width (o) short *nHeight : height
Return value FALSE : failed TRUE : succeeded
Details Gets the current font size for the specified font handle.
File name GFGetSize.c
56
Page 62
2. GDraw
GFLoadFont
GFLoadFont.c Outline Load specified font
Syntax HGFONT GFLoadFont( char *pszFontName )
Argument (i) char *pszFontName : font name
Return value Font handle
Details Sets the specified font to a usable status and returns the handle.
File name GFLoadFont.c
2.2 Descriptions of GDraw Functions
GFReleaseFont
GFReleaseFont.c Outline Release font
Syntax void GFReleaseFont( HGFONT hFont )
Argument (i) HGFONT hFont : font
Return value None
Details Releases the font for the specified handle.
File name GFReleaseFont.c
57
Page 63
2. GDraw
GFSetFontAttribute
GFSetFontAttribute.c Outline Set font attributes
Syntax short GFSetFontAttribute( HGFONT hFont, GFontAttribute *pgfaAttribute )
Argument (i) HGFONT hFont : font (i) GFontattribute *pgfaAttribute : attribute
Return value FALSE : failed TRUE : succeeded
Details Sets the attributes for the specified font.
File name GFSetFontAttribute.c
2.2 Descriptions of GDraw Functions
GFSetFontUserAttribute
GFSetFontUserAttribute.c Outline Set font user attributes
Syntax short GFSetFontUserAttribute( HGFONT hFont, short *pnAttributeArray )
Argument (i) HGFONT hFont : font (i) short *pnAttributeArray : attribute unique to platform
Return value FALSE : failed TRUE : succeeded
Details Sets the font attributes peculiar to the font handle.
File name GFSetFontUserAttribute.c
58
Page 64
2. GDraw
GFSetSize
GFSetSize.c Outline Set character size
Syntax short GFSetSize( HGFONT hFont, short nWidth, short nHeight )
Argument (i) HGFONT hFont : font being specified (i) short nWidth : width (i) short nHeight : height
Return value FALSE : failed TRUE : succeeded
Details Sets the character size for the specified font.
File name GFSetSize.c
2.2 Descriptions of GDraw Functions
GRDuplicateRect
GRDuplicateRect.c Outline Copy rectangle
Syntax void GRDuplicateRect( GRect *pgrSrc, GRect *pgrDest )
Argument (i) GRect *pgrSrc : copy source (o) GRect *pgrDest : copy destination
Return value None
Details Copies the rectangular area defined in pgrSrc to the pgrDest rectangular area.
File name GRDuplicateRect.c
59
Page 65
2. GDraw
GREqualRect
GREqualRect.c Outline Confirm that rectangle areas are the same
Syntax short GREqualRect( GRect *pgrSrc1, GRect *pgrSrc2 )
Argument (i) GRect *pgrSrc1 : rectangle area (i) GRect *pgrSrc2 : rectangle area
Return value FALSE : not the same TRUE : same
Details Finds out if the rectangular areas defined in pgrS rc1 and pgrSrc2 a re the same.
File name GREqualRect.c
2.2 Descriptions of GDraw Functions
60
Page 66
2. GDraw
GRGetRect
GRGetRect.c Outline Get rectangle area
Syntax void GRGetRect( GRect *pgrRect, short *nX1, short *nY1, short *nX2, short *nY2 )
Argument (i) GRect *pgrRect : rectangle area (o) short *nX1 : X coordinate for upper left corner (o) short *nY1 : Y coordinate for upper left corner (o) short *nX2 : X coordinate for lower right corner (o) short *nY2 : Y coordinate for lower right corner
Return value None
Details Gets the rectangle area. The rectangle's upper left corner coordinates will be set in (nX1, nY1) and the
File name GRGetRect.c
2.2 Descriptions of GDraw Functions
lower right corner coordinates will be set in (nX2, nY2).
61
Page 67
2. GDraw
GRInceptRect
GRInceptRect.c Outline Confirm rectangular area overlap
Syntax short GRInceptRect( GRect *pgrSrc1, GRect *pgrSrc2, GRect *pgrDest )
Argument (i) GRect *pgrSrc1 : rectangle area (i) GRect *pgrSrc2 : rectangle area (o) GRect *pgrDest : rectangle area
Return value FALSE : pgrSrc1 and pgrSrc2 do not overlap. (pgrDest not determined) TRUE : pgrSrc1 and pgrSrc2 overlap.
Details Finds out if the two rectangular areas in pgrSrc1 and pgrSrc2 overlap. If they overlap, set that area in pgrDest.
File name GRInceptRect.c
2.2 Descriptions of GDraw Functions
62
Page 68
2. GDraw
GRMapRect
GRMapRect.c Outline Enlarge/reduce rectangular area
Syntax void GRMapRect( GRect *pgrRect, GRect *pgrFrom, GRect *pgrTo )
Argument (i/o) GRect *pgrRect : rectangle area (i) GRect *pgrFrom : rectangle area (i) GRect *pgrTo : rectangle area
Return value None
Details
File name GRMapRect.c
2.2 Descriptions of GDraw Functions
Converts the rectangular area defined in pgrRect in the same proportion as the conversion of the rectangular area defined in pgrFrom to the rectangular area defined in PgrTo.
GRMapToScreenRect
GRMapToScreenRect.c Outline Convert rectangular area defined in pgrRect to actual screen coordinate system
Syntax void GRMapToScreenRect( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GRect *pgrRect : rectangle
Return value None
Details
File name GRMapToScreenRect.c
Converts the rectangular area defined in pgrRect to the actual screen coordinate system
63
Page 69
2. GDraw
GRMapToVirtualRect
GRMapToVirtualRect.c Outline
Syntax void GRMapToVirtualRect( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangular area
Return value None
Details
File name GRMapToVirtualRect.c
2.2 Descriptions of GDraw Functions
Convert the rectangular area defined in pgrRect to the virtual screen coordinate system
Converts the rectangular area defined in pgrRect to the virtual screen coordinate system
GROffsetRect
GROffsetRect.c Outline Rectangle offset processing
Syntax void GROffsetRect( GRect *pgrRect, short nDx, short nDy )
Argument (i/o) GRect *pgrRect : source rectangular area (i) short nDx : increase in X direction (i) short nDy : increase in Y direction
Return value None
Details
File name GROffsetRect.c
Moves the rectangle defined in pgrRect nDx and nDy in the X direction and Y direction, respectively.
64
Page 70
2. GDraw
GRPhysicalToVirtualRect
GRPhysicalToVirtualRect.c Outline Convert rectangle physical coordinates to virtual coordinates
Syntax void GRPhysicalToVirtualRect( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GRect *pgrRect : rectangle area
Return value None
Details
File name GRPhysicalToVirtualRect.c
2.2 Descriptions of GDraw Functions
Converts the rectangular area defined in pgrRect from physical (local) coordinates to virtual coordinates.
GRPointInRect
GRPointInRect.c Outline Check if point coordinates fall within rectangle coordinates
Syntax short GRPointInRect( GPoint *pptPoint, GRect *pgrRect )
Argument (i) GPoint *pptPoint : point coordinates (i) GRect *pgrRect : rectangle area
Return value FALSE : not inside TRUE : inside (including on the pgrRect)
Details
File name GRPointInRect.c
Finds out if the point coordinates defined in pptPoint are within the rectangular area defined in pgrRect.
65
Page 71
2. GDraw
GRResizeRect
GRResizeRect.c Outline Resize rectangle
Syntax void GRResizeRect( GRect *pgrRect, short nDx, short nDy )
Argument (i/o) GRect *pgrRect : rectangle area (i) short nDx : increase in X direction (i) short nDy : increase in Y direction
Return value None
Details
Furthermore, nDy is subtracted from the initial Y coordinate and nDy is added
File name GRResizeRect.c
2.2 Descriptions of GDraw Functions
nDx is subtracted from the initial X coordinate of pgrRect and nDx is added to the final X coordinate.
to the final Y coordinate.
66
Page 72
2. GDraw
GRSetRect
GRSetRect.c Outline Define rectangular area
Syntax void GRSetRect( GRect *pgrRect, short nX1, short nY1, short nX2, short nY2 )
Argument (o) GRect *pgrRect1 : rectangle area (i) short nX1 : X coordinate for upper left corner (i) short nY1 : Y coordinate for upper left corner (i) short nX2 : X coordinate for lower right corner (i) short nY2 : Y coordinate for lower right corner
Return value None
Details
File name GRSetRect.c
2.2 Descriptions of GDraw Functions
The coordinates for the rectangle’s upper left corner are specified as (nX1, nY1) and those for the lower right corner as (nX2, nY2).
67
Page 73
2. GDraw
GRShiftRect
GRShiftRect.c Outline Rectangle shift processing
Syntax short GRShiftRect( GRect *pgrRect, short nDx, short nDy, GRect *pgrRect1, GRect *pgrRect2 )
Argument (i) GRect *pgrRect : source rectangular area (i) short nDx : increase in X direction (i) short nDy : increase in Y direction (o) GRect *pgrRect1 : empty rectangular area (o) GRect *pgrRect2 : empty rectangular area
Return value 0 : no empty rectangular area 1 : one empty rectangular area 2 : two empty rectangular areas
Details
File name GRShiftRect.c
2.2 Descriptions of GDraw Functions
Moves the rectangle defined in pgrRect nDx and nDy in the X direction and Y direction, respectively. Furthermore, the empty rectangular area created by the movement is set in pgrRect1 and pgrRect2.
68
Page 74
2. GDraw
GRUnionRect
GRUnionRect.c Outline Join rectangle areas
Syntax void GRUnionRect( GRect *pgrSrc1, GRect *pgrSrc2, GRect *pgrDest )
Argument (i) GRect *pgrSrc1 : rectangle area (i) GRect *pgrSrc2 : rectangle area (o) GRect *pgrDest : combined rectangular area
Return value None
Details
File name GRUnionRect.c
2.2 Descriptions of GDraw Functions
The minimum sized rectangular area surrounding the specified rectangular areas pgrSrc1 and pgrSrc2 is set in pgrDest.
GRVirtualT oPhy sicalRect
GRVirtualToPhysicalRect.c Outline Convert rectangular area virtual coordinates to physical coordinates
Syntax void GRVirtualToPhysicalRect( HGDRAW hDraw, GRect *pgrRect )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GRect *pgrRect : rectangle area
Return value None
Details
File name GRVirtualToPhysicalRect.c
Converts the rectangular area defined in pgrRect from virtual coordinates to physical (local) coordinates.
69
Page 75
2. GDraw
GLDuplicateLine
GLDuplicateLine.c Outline Copy line structure
Syntax void GLDuplicateLine( GLine *pglSrc, GLine *pglDest )
Argument (i) GLine *pglSrc : copy source (o) GLine *pglDest : copy destination
Return value None
Details The line structure defined in pglSrc is copied to the line structure in pglDest.
File name GLDuplicateLine.c
2.2 Descriptions of GDraw Functions
70
Page 76
2. GDraw
GLGetLine
GLGetLine.c Outline Get line
Syntax void GLGetLine( GLine *pglLine, short *nX1, short *nY1, short *nX2, short *nY2 )
Argument (i) GLine *pglLine : source line structure being acquired (o) short *nX1 : X coordinate for starting point of line structure (o) short *nY1 : Y coordinate for starting point of line structure (o) short *nX2 : X coordinate for ending point of line structure (o) short *nY2 : Y coordinate for ending point of line structure
Return value None
Details Gets the content of the line structure pglLine in (nX1,nY1) and (nX2,nY2)
File name GLGetLine.c
2.2 Descriptions of GDraw Functions
71
Page 77
2. GDraw
GLMapLine
GLMapLine.c Outline Enlarge/reduce line coordinates
Syntax void GLMapLine( GLine *pglLine, GRect *pgrFrom, GRect *pgrTo )
Argument (i/o) GLine *pglLine : line structure (i) GRect *pgrForm : rectangle area (i) GRect *pgrTo : rectangle area
Return value None
Details
File name GLMapLine.c
2.2 Descriptions of GDraw Functions
Converts coordinates when the line structure in the pgrFrom rectangular area will be projected onto to the pgrTo rectangular area.
72
Page 78
2. GDraw
GLOffsetLine
GLOffsetLine.c Outline Offset processing for line structure
Syntax void GLOffsetLine( GLine *pglLine, short nDx, short nDy )
Argument (i/o) GLine *pglLine : source line (i) short nDx : increase in X direction (i) short nDy : increase in Y direction
Return value None
Details
File name GLOffsetLine.c
2.2 Descriptions of GDraw Functions
Moves the line defined in pglLine nDx and nDy in the X direction and Y direction, respectively.
GLPhysicalToVirtualLine
GLPhysicalToVirtualLine.c Outline Convert line structure physical coordinates to virtual coordinates
Syntax void GLPhysicalToVirtualLine( HGDRAW hDraw, GLine *pglLine )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GLine *pglLine : line structure
Return value None
Details
File name GLPhysicalToVirtualLine.c
Converts the coordinates defined in pglLine from physical (local) coordinates to virtual coordinates.
73
Page 79
2. GDraw
GLSetLine
GLSetLine.c Outline Define line structure
Syntax void GLSetLine( GLine *pglLine, short nX1, short nY1, short nX2, short nY2 )
Argument (o) GLine *pglLine : line structure (i) short nX1 : X coordinate for starting point (i) short nY1 : Y coordinate for starting point (i) short nX2 : X coordinate for ending point (i) short nY2 : Y coordinate for ending point
Return value None
Details
File name GLSetLine.c
2.2 Descriptions of GDraw Functions
Defines a line structure. The coordinates for the starting point of a line are specified as (nX1, nY1) and those for the ending point as (nX2, nY2).
74
Page 80
2. GDraw
GLVirtualToPhysicalLine
GLVirtualToPhysicalLine.c Outline Convert line structure virtual coordinates to physical coordinates
Syntax void GLVirtualToPhysicalLine( HGDRAW hDraw, GLine *pglLine )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GLine *pglLine : line structure
Return value None
Details
File name GLVirtualToPhysicalLine.c
2.2 Descriptions of GDraw Functions
Converts the coordinates defined in pglLine from virtual coordinates to physical (local) coordinates.
GPTDuplicatePoint
GPTDuplicatePoint.c Outline Copy point structure
Syntax void GPTDuplicatePoint( GPoint *pgptSrc, GPoint *pgptDest )
Argument (i) GPoint *pgptSrc : copy source (o) GPoint *pgptDest : copy destination
Return value None
Details The point structure defined in pgptSrc is copied to pgptDest.
File name GPTDuplicatePoint.c
75
Page 81
2. GDraw
GPTGetPoint
GPTGetPoint.c Outline Get point structure content
Syntax void GPTGetPoint( GPoint *pgptPoint, short *nX, short *nY )
Argument (i) GPoint *pgptPoint : point structure for acquisition source (o) short *nX : X coordinate for point structure (o) short *nY : Y coordinate for point structure
Return value None
Details Gets the content of point structure pgptPoint in (nX, nY).
File name GPTGetPoint.c
2.2 Descriptions of GDraw Functions
GPTMapPoint
GPTMapPoint.c Outline Relative conversion of point coordinates
Syntax void GPTMapPoint( GPoint *pgptPoint, GRect *pgrFrom, GRect *pgrTo )
Argument (i/o) GPoint *pgptPoint : point structure (i) GRect *pgrFrom : rectangle area (i) GRect *pgrTo : rectangle area
Return value None
Details
File name GPTMapPoint.c
Converts coordinates when the point structure in the pgrFrom rectangular area will be projected onto to the pgrTo rectangular area.
76
Page 82
2. GDraw
GPTMapToScreenPoint
GPTMapToScreenPoint.c Outline Convert point structure to screen coordinates
Syntax void GPTMapToScreenPoint( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GPoint *pgptPoint : point coordinates
Return value None
Details Converts the point defined in pgptPoint to the actual screen coordinate system.
File name GPTMapToScreenPoint.c
2.2 Descriptions of GDraw Functions
GPTMapToVirtualPoint
GPTMapToVirtualPoint.c Outline Convert point defined in pgptPoint to virtual screen coordinate system
Syntax void GPTMapToVirtualPoint( HGDRAW hDraw, GPoint * pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GPoint *pgptPoint : point structure
Return value None
Details Converts the point defined in pgptPoint to the virtual screen coordinate system.
File name GPTMapToVirtualPoint.c
77
Page 83
2. GDraw
GPTOffsetPoint
GPTOffsetPoint.c Outline Point structure offset processing
Syntax void GPTOffsetPoint( GPoint *pgptPoint, short nDx, short nDy )
Argument (i/o) GPoint *pgptPoint : point structure for movement source (i) short nDx : increase in X direction (i) short nDy : increase in Y direction
Return value None
Details
File name GPTOffsetPoint.c
2.2 Descriptions of GDraw Functions
Moves the point structure pgptPoint nDx and nDy in the X direction and Y direction, respectively.
GPTPhysicalToVirtualPoint
GPTPhysicalToVirtualPoint.c Outline Convert point structure physical coordinates to virtual coordinates
Syntax void GPTPhysicalToVirtualPoint( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GPoint *pgptPoint : point structure
Return value None
Details
File name GPTPhysicalToVirtualPoint.c
Converts the point defined in pgptPoint from physical (local) coordinates to virtual coordinates.
78
Page 84
2. GDraw
GPTSetPoint
GPTSetPoint.c Outline Define point structure
Syntax void GPTSetPoint( GPoint *pgptPoint, short nX, short nY )
Argument (o) GPoint *pgptPoint : point structure (i) short nX : coordinate in X direction (i) short nY : coordinate in Y direction
Return value None
Details Sets the (nX, nY) coordinates in the point structure pgptPoint.
File name GPTSetPoint.c
2.2 Descriptions of GDraw Functions
GPTVirtualToPhysicalPoint
GPTVirtualToPhysicalPoint.c Outline Convert point structure virtual coordinates to physical coordinates
Syntax void GPTVirtualToPhysicalPoint( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GPoint *pgptPoint : point structure
Return value None
Details
File name GPTVirtualToPhysicalPoint.c
Converts the point specified by pgptPoint from virtual coordinates to physical coordinates.
79
Page 85
2. GDraw
GPGetPoly
GPGetPoly.c Outline Get polygon settings
Syntax void GPGetPoly( GPoly *pgpPolygon, short *nNumPoints, GPoint **pgptPoints, GRect *pgrBounds )
Argument (i) GPoly *pgpPolygon : polygon structure for acquisition source (o) short *nNumPoints : number of vertices (o) GPoint **pgptPoints : point structure (o) GRect *pgrBounds : rectangle area
Return value None
Details
File name GPGetPoly.c
2.2 Descriptions of GDraw Functions
Gets the polygon structure pgpPolygon content in nNumPoints, pgptPoints and pgrBounds.
80
Page 86
2. GDraw
GPMapPoly
GPMapPoly.c Outline Enlarge/reduce polygon
Syntax void GPMapPoly( GPoly * pgpPolygon, GRect * pgrFrom, GRect * pgrTo )
Argument (i/o) GPoly *pgpPolygon : polygon structure (i) GRect *pgrFrom : rectangular area (i) GRect *pgrTo : rectangular area
Return value None
Details
File name GPMapPoly.c
2.2 Descriptions of GDraw Functions
Converts coordinates when the polygon structure in the pgrFrom rectangular area will be projected onto to the pgrTo rectangular area.
81
Page 87
2. GDraw
GPOffsetPoly
GPOffsetPoly.c Outline Polygon offset processing
Syntax void GPOffsetPoly( GPoly *pgpPolygon, short nDx, short nDy )
Argument (i/o) GPoly *pgpPolygon : polygon for movement source (i) short nDx : increase in X direction (i) short nDy : increase in Y direction
Return value None
Details
File name GPOffsetPoly.c
2.2 Descriptions of GDraw Functions
Moves the polygon defined in pgpPolygon nDx and nDy in the X direction and Y direction, respectively.
GPPhysicalToVirtualPoly
GPPhysicalToVirtualPoly.c Outline Convert polygon physical coordinates to virtual coordinates
Syntax void GPPhysicalToVirtualPoly( HGDRAW hDraw, GPoly *pgpPolygon )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GPoly *pgpPolygon : polygon structure
Return value None
Details
File name GPPhysicalToVirtualPoly.c
Converts the polygon structure defined in pgpPolygon from physical (local) coordinates to virtual coordinates.
82
Page 88
2. GDraw
GPSetPoly
GPSetPoly.c Outline Define polygon
Syntax void GPSetPoly( GPoly *pgpPolygon, short nNumPoints, GPoint *pgptPoints, GRect *pgrBounds )
Argument (o) GPoly *pgpPolygon : polygon structure (i) short nNumPoints : number of vertices (i) GPoint *pgptPoints : point structure (i) GRect *pgrBounds : rectangle area
Return value None
Details
File name GPSetPoly.c
2.2 Descriptions of GDraw Functions
Sets nNumPoints, pgptPoints and pgrBounds in the polygon structure pgpPolygon.
GPVirtualToPhysicalPoly
GPVirtualToPhysicalPoly.c Outline Convert polygon virtual coordinates to physical coordinates
Syntax void GPVirtualToPhysicalPoly( HGDRAW hDraw, GPoly *pgpPolygon )
Argument (i/o) HGDRAW hDraw : drawing handle (i/o) GPoly *pgpPolygon : polygon structure
Return value None
Details
File name GPVirtualToPhysicalPoly.c
Converts the polygon structure defined in pgpPolygon from virtual coordinates to local (physical) coordinates.
83
Page 89
2. GDraw
GMSetMemorySpace
GMemory.c Outline Register memory area information
Syntax short GMSetMemorySpace( unsigned char ucMemorySpaceCount, GMemorySpaceInformation *paMemorySpace )
Argument
(i) GMemorySpaceInformation *paMemorySpace
Return value 0 : registration failed 1 or more : number of pieces of memory area data successfully registered
Details
File name GMemory.c
2.2 Descriptions of GDraw Functions
(i) unsigned char ucMemorySpaceCount
: number of pieces of data for memory area to be registered
: pointer to memory area information array
GMemorySpaceInformation is set in GUI library 2 for the number specified by ucMemorySpaceCount. GMemorySpaceInformation is passed to paMemorySpace as an array for the number specified by ucMemorySpaceCount. GPISetMemorySpace is called for the internal processing.
84
Page 90
2. GDraw
GMDeleteMemorySpace
GMemory.c Outline Delete registered memory area
Syntax short GMDeleteMemorySpace( unsigned char ucType, unsigned char ucPlane )
Argument (i) unsigned char ucType : memory area type to be deleted (i) unsigned char ucPlane : memory plane No. for deletion
Return value FALSE : Deletion failed TRUE : Deletion succeeded
Details The registered memory area specified by ucType and ucPlane is deleted. GPIDeleteMemorySpace is called for the internal processing.
File name GMemory.c
2.2 Descriptions of GDraw Functions
85
Page 91
2. GDraw
GMMemoryAlloc
GMemory.c Outline Allocate memory area
Syntax void* GMMemoryAlloc( unsigned char ucType, unsigned char ucPlane, unsigned long ulMemorySpaceSize )
Argument
GMEM_SPACE_GDRAW(1) : memory area used by Gdraw GMEM_SPACE_GPI(4) : memory area used by GPI GMEM_SPACE_GWIN(5) : memory area used by GWin GMEM_SPACE_GWIN_PANEL(6) : memory area used by GWin base GMEM_SPACE_GWIN_WINDOW(7) : memory area used by GWin
(i) unsigned char ucPlane : memory area plane No. for memory
(i) unsigned long ulMemorySpaceSize : size of memory being allocated
Return value NULL : memory allocation failed Other than NULL : start of address for memory allocated
Details Allocates memory of the specified size from the specified memory area. When allocation fails, a NULL is returned as a return value. GPIMemoryAlloc is called for the internal processing.
File name GMemory.c
2.2 Descriptions of GDraw Functions
(i) unsigned char ucType : type of memory area for memory
being allocated
window
being allocated
86
Page 92
2. GDraw
GMMemoryFree
GMemory.c Outline Release memory area
Syntax short GMMemoryFree ( unsigned char ucType, unsigned char ucPlane, void* pvMemory *pvMemory )
Argument
GMEM_SPACE_GDRAW(1) : memory area used by Gdraw GMEM_SPACE_GPI(4) : memory area used by GPI GMEM_SPACE_GWIN(5) : memory area used by GWin GMEM_SPACE_GWIN_PANEL(6) : memory area used by GWin base GMEM_SPACE_GWIN_WINDOW(7) : memory area used by GWin
GMEM_SPACE_USER(8) : memory area used by user (i) unsigned char ucPlane : memory area plane No. for
(i) void *pvMemory : address of memory being released
Return value FALSE : memory release failed TRUE : memory release succeeded
Details
File name GMemory.c
2.2 Descriptions of GDraw Functions
(i) unsigned char ucType : type of memory area for memory to
be released
window
memory being released
Releases memory allocated from the specified memory area. GPIMemoryFree is called for the internal processing.
87
Page 93
2. GDraw
GDCreateVram
GDCreateVram.c Outline Create virtual VRAM
Syntax HGVRAM GDCreateVram( GVram *pVram )
Argument (i) GVram *pVram : VRAM structure
Return value VRAM handle
Details Creates virtual VRAM based on the information set in the VRAM structure.
File name GDCreateVram.c
2.2 Descriptions of GDraw Functions
GDDeleteVram
GDDeleteVram.c Outline Release virtual VRAM
Syntax void GDDeleteVram( HGVRAM hVram )
Argument (i/o) HGVRAM hVram : VRAM handle
Return value VRAM handle
Details Releases the virtual VRAM corresponding to the specified VRAM handle.
File name GDDeleteVram.c
88
Page 94
2. GDraw
GDFlushScreenForce
GDFlushScreenForce.c Outline Forcible refresh screen
Syntax void GDFlushScreenForce( HGDRAW hDraw, short nX, short nY, short nWidth, short nHeight )
Argument (i/o) HGDRAW hDraw : drawing handle (i) short nX : X coordinate for drawing starting point (i) short nY : Y coordinate for drawing starting point (i) short nWidth : drawing area width (i) short nHeight : drawing area height
Return value None
Details
File name GDFlushScreenForce.c
2.2 Descriptions of GDraw Functions
A screen for the size of nWidth*Height is forcibly refreshed in the current coordinate system with the specified point (nX, nY) as the starting point.
89
Page 95
2. GDraw
GDGetGradationInfo
GDGetGradationInfo.c Outline Get gradation information
Syntax void GDGetGradationInfo( HGDRAW hDraw, GGradationInfo *pggInfo )
Argument (i/o) HGDRAW hDraw : drawing handle (o) GGradationInfo *pggInfo : gradation information structure
Return value None
Details Gets gradation information.
File name GDGetGradationInfo.c
2.2 Descriptions of GDraw Functions
GDGetLocalOrigin
GDGetLocalOrigin.c Outline Get local coordinate origin
Syntax void GDGetLocalOrigin( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (o) GPoint *pgptPoint : point structure
Return value None
Details Gets local (physical) coordinate origin.
File name GDGetLocalOrigin.c
90
Page 96
2. GDraw
GDGetVram
GDGetVram.c Outline Get system VRAM
Syntax HGVRAM GDGetVram( HGDRAW hDraw )
Argument (i/o) HGDRAW hDraw : drawing handle
Return value HGVRAM : system VRAM handle
Details Gets system VRAM.
File name GDGetVram.c
2.2 Descriptions of GDraw Functions
GDRemoveDrawableRegion
GDRemoveDrawableRegion.c Outline Delete specified rectangular area from drawable area
Syntax short GDRemoveDrawableRegion( HGDRAW hDraw, GRect * pRect )
Argument (i/o) HGDRAW hDraw : drawing handle (o) GRect *pRect : rectangle area to be deleted
Return value FALSE : failed TRUE : succeeded
Details
File name GDRemoveDrawableRegion.c
Deletes the rectangular area specified by pRect from the drawable area held by the platform.
91
Page 97
2. GDraw
GDSetDrawableRegion
GDSetDrawableRegion.c Outline Set drawable area
Syntax short GDSetDrawableRegion( HGDRAW hDraw, GRect * pRect )
Argument (i/o)HGDRAW hDraw : drawing handle (i)GRect *pRect : rectangular area being set
Return value FALSE : failed TRUE : succeeded
Details Sets the drawable area held by the platform.
File name GDSetDrawableRegion.c
2.2 Descriptions of GDraw Functions
GDSetGradationInfo
GDSetGradationInfo.c Outline Set gradation information
Syntax void GDSetGradationInfo( HGDRAW hDraw, GGradationInfo *pggInfo )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GGradationInfo *pggInfo : gradation information structure
Return value None
Details Sets gradation information.
File name GDSetGradationInfo.c
92
Page 98
2. GDraw
2.2 Descriptions of GDraw Functions
GDSetLocalOrigin
GDSetLocalOrigin.c Outline Set local coordinate origin
Syntax void GDSetLocalOrigin( HGDRAW hDraw, GPoint *pgptPoint )
Argument (i/o) HGDRAW hDraw : drawing handle (i) GPoint *pgptPoint : point structure
Return value None
Details
File name GDSetLocalOrigin.c
Values for pgptPoint.nX in the X direction and pgptPoint.nY in the Y direction are set for the origin for the local (physical) coordinates.
93
Page 99

3. GResource

3.1 List of GResource Functions

3. GResource
This section describes the GResource functions.
3.1 List of GResource Functions
No. Name Type File name Outline
1 GRCLoadBorder GBorder * GRCLoadBorder.c Get specified ID 3D border resource 2 GRCLoadFont GSimpleFont * GRCLoadFont.c Get specified ID font resource 3 GRCLoadImage GImage * GRCLoadImage.c Get specified ID image resource 4 GRCLoadString char * GRCLoadString.c Get specified ID character string
resource
5 GRCLoadLocaleFont GSimpleFont * GRCLoadLocaleFont.c Get font resource for specified
locale specified ID
6 GRCLoadLocaleString GTCHAR * GRCLoadLocaleString.c Get character string resource for
specified locale specified ID
7 GRCLoadPalette GPaletteHeader * GRCLoadPalette.c Get specified ID palette resource
8 GRCSetLocale short GRCLocale.c Current locale setting
9 GRCGetLocale unsigned char GRCLocale.c Get current locale 10 GRCLoadFillPattern char * GRCLoadFillPattern.c Get fill pattern for specified No. 11 GRCLoadHtmlFileNa
me
12 GRCLoadLanguageS
tr
13 GRCLoadNowLangu
ageStr
14 GRCLoadLinePattern char * GRCLoadLinePattern.c Get line drawing pattern for
15 GRCSetResourceHa
ndle
16 GRCGetResourceHa
ndle
17 GRCUnicodeToMulti
Byte
18 GRCMultiByteToUnic
ode
GFileName* GRCLoadHtmlFileNam
e.c
GTCHAR * GRCLoadLanguageStr.c Get specified locale
GTCHAR * GRCLoadLanguageStr.c Get current locale
void GRCResourceHandle.c Set current resource handle
HGRESOURCE GRCResourceHandle.c Get current resource handle
unsigned long GRCUnicode.c UNICODE multibyte conversion
unsigned long GRCUnicode.c Multibyte UNICODE conversion
Get HTML file name for specified ID
language-identifying character strings resource
language-identifying character strings resource
specified No.
94
Page 100
3. GResource

3.2 Outlines of GResource Functions

GRCLoadBorder
GRCLoadBorder.c Outline Get specified ID 3D border resource
Syntax GBorder *GRCLoadBorder( unsigned short usResourceID )
Argument (i) unsigned short usResourceID : resource ID
Return value Specified resource
Details Gets the pointer to the 3D border resource structure with the specified ID.
File name GRCLoadBorder.c
3.2 Descriptions of GResource Functions
GRCLoadFont
GRCLoadFont.c Outline Get specified ID font resource
Syntax GSimpleFont *GRCLoadFont( unsigned short usResourceID )
Argument (i) unsigned short usResourceID : resource ID
Return value Specified resource
Details Gets the pointer to the simple font resource structure with the specified ID.
File name GRCLoadFont.c
95
Loading...