petsc-3.7.1 2016-05-15
Report Typos and Errors

PetscViewerDrawOpen

Opens a window for use as a PetscViewer. If you want to do graphics in this window, you must call PetscViewerDrawGetDraw() and perform the graphics on the PetscDraw object.

Synopsis

#include "petscdraw.h" 
#include "petscviewer.h" 
PetscErrorCode  PetscViewerDrawOpen(MPI_Comm comm,const char display[],const char title[],int x,int y,int w,int h,PetscViewer *viewer)
Collective on MPI_Comm Many br

Input Parameters

comm - communicator that will share window Many br
display - the X display on which to open, or null for the local machine Many br
title - the title to put in the title bar, or null for no title Many br
x, y - the screen coordinates of the upper left corner of window, or use PETSC_DECIDE Many br
w, h - window width and height in pixels, or may use PETSC_DECIDE or PETSC_DRAW_FULL_SIZE, PETSC_DRAW_HALF_SIZE, Many brPETSC_DRAW_THIRD_SIZE, PETSC_DRAW_QUARTER_SIZE Many br

Output Parameters

viewer -the PetscViewer Many br

Format Options

PETSC_VIEWER_DRAW_BASIC - displays with basic format Many br
PETSC_VIEWER_DRAW_LG - displays using a line graph Many br

Options Database Keys

PetscViewerDrawOpen() calls PetscDrawCreate(), so see the manual page for Many brPetscDrawCreate() for runtime options, including Many br
-draw_type x or null- . -nox - Disables all x-windows output Many br
-display <name> - Specifies name of machine for the X display Many br
-geometry <x,y,w,h> - allows setting the window location and size Many br
-draw_pause <pause> - Sets time (in seconds) that the Many brprogram pauses after PetscDrawPause() has been called Many br(0 is default, -1 implies until user input). Many br

Many br

Note for Fortran Programmers

Whenever indicating null character data in a Fortran code, Many brNULL_CHARACTER must be employed; using NULL is not Many brcorrect for character data! Thus, NULL_CHARACTER can be Many brused for the display and title input parameters. Many br

See Also

PetscDrawCreate(), PetscViewerDestroy(), PetscViewerDrawGetDraw(), PetscViewerCreate(), PETSC_VIEWER_DRAW_,
PETSC_VIEWER_DRAW_WORLD, PETSC_VIEWER_DRAW_SELF Many br

Level:beginner
Location:
src/sys/classes/viewer/impls/draw/drawv.c
Index of all Viewer routines
Table of Contents for all manual pages
Index of all manual pages

Examples

src/vec/vec/examples/tutorials/ex3.c.html
src/vec/vec/examples/tutorials/ex3f.F.html
src/dm/examples/tutorials/ex1.c.html
src/dm/examples/tutorials/ex2.c.html
src/dm/examples/tutorials/ex5.c.html
src/snes/examples/tutorials/ex2.c.html
src/snes/examples/tutorials/ex3.c.html
src/snes/examples/tutorials/ex21.c.html
src/snes/examples/tutorials/ex22.c.html
src/snes/examples/tutorials/ex74f.F90.html
src/ts/examples/tutorials/ex2.c.html