- AppGraphics Documentation
- Getting Started with AppGraphics
- Window Management
- Colors and Patterns
- Mouse Interactions
- Keyboard Interaction
- Graphics Shapes and Primitives
- Text Output
- Graphic Viewports
- Images
- Windows Controls
- Common Dialogs
- Clipboard Operations
- Threads, Thread Safety, and Idling
- AppGraphics License Agreement
Graphic Viewports
The following procedures can be used to configure viewports within a window. A viewport is useful for retricting graphics operations to a certain region within a window. By default, the viewport is the entire window.
clearviewport
C void clearviewport ( )
Fortran subroutine clearviewport ( )
Description
Clears the current viewport, filling the area with the background color
getviewsettings
C void getviewsettings ( viewport )
Fortran subroutine getviewsettings ( viewport )
Description
Retrieves the current viewport settings.
Parameters
Parameter | C Type | Fortran Type | Description |
viewport | viewporttype * | type(viewporttype), intent(out) | Pointer to the structure to fill with the viewport details |
resetviewport
C void resetviewport ( )
Fortran subroutine resetviewport ( )
Description
Resets the viewport to include the entire current window
setviewport
C void setviewport ( left, top, right, bottom, clip )
Fortran subroutine setviewport ( left, top, right, bottom, clip )
Description
Configures the current viewport within the current window. Drawing can be clipped to be within the viewport if clip is set to 1.
Parameters
Parameter | C Type | Fortran Type | Description |
left | int | integer | Leftmost horizontal position of the viewport |
top | int | integer | topmost vertical position of the viewport |
right | int | integer | Rightmost horizontal position of the viewport |
bottom | int | integer | Bottommost vertical position of the viewport |
clip | int | logical | If set to 1 or .TRUE., clips, or restricts, graphic operations to the viewport |