petsc-3.8.4 2018-03-24
Report Typos and Errors

PetscDrawGetMouseButton

Returns location of mouse and which button was pressed. Waits for button to be pressed.

Synopsis

#include "petscdraw.h" 
PetscErrorCode  PetscDrawGetMouseButton(PetscDraw draw,PetscDrawButton *button,PetscReal *x_user,PetscReal *y_user,PetscReal *x_phys,PetscReal *y_phys)
Collective over PetscDraw

Input Parameter

draw -the window to be used

Output Parameters

button - one of PETSC_BUTTON_LEFT, PETSC_BUTTON_CENTER, PETSC_BUTTON_RIGHT, PETSC_BUTTON_WHEEL_UP, PETSC_BUTTON_WHEEL_DOWN
x_user, y_user - user coordinates of location (user may pass in NULL).
x_phys, y_phys - window coordinates (user may pass in NULL).

Notes: Only processor 0 actually waits for the button to be pressed.

Level:intermediate
Location:
src/sys/classes/draw/interface/dmouse.c
Index of all Draw routines
Table of Contents for all manual pages
Index of all manual pages