DrawOpenX

Opens an X-window for use with the Draw routines.

Synopsis

int DrawOpenX(MPI_Comm comm,char* display,char *title,int x,int y,int w,int h,Draw* inctx)
Collective on MPI_Comm

Input Parameters

comm - the communicator that will share X-window
display - the X display on which to open, or null for the local machine
title - the title to put in the title bar, or null for no title
x, y - the screen coordinates of the upper left corner of window
may use PETSC_DECIDE for these two arguments, then PETSc places the - . window
w, h - the screen width and height in pixels

Output Parameters

ctx -the drawing context.

Options Database Keys

-nox - Disables all x-windows output
-display <name> - Sets name of machine for the X display
-draw_pause <pause> - Sets time (in seconds) that the program pauses after DrawPause() has been called (0 is default, -1 implies until user input).
-draw_x_shared_colormap - Causes PETSc to use a shared colormap. By default PETSc creates a seperate color for its windows, you must put the mouse into the graphics window to see the correct colors. This options forces PETSc to use the default colormap which will usually result in bad contour plots.
-draw_double_buffer - Uses double buffering for smooth animation.
-geometry - Indicates location and size of window

Note

When finished with the drawing context, it should be destroyedwith DrawDestroy().

Note for Fortran Programmers

Whenever indicating null character data in a Fortran code, PETSC_NULL_CHARACTER must be employed; using PETSC_NULL is notcorrect for character data! Thus, PETSC_NULL_CHARACTER can beused for the display and title input parameters.

Keywords

draw, open, x

See Also

DrawSynchronizedFlush(), DrawDestroy()

Examples

src/snes/examples/tutorials/ex4f.F
src/snes/examples/tutorials/ex4.c

Location: src/draw/impls/x/xops.c
Graphics (Draw) Index
Table of Contents