<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Feb 12, 2016 at 3:26 AM, Florian Lindner <span dir="ltr"><<a href="mailto:mailinglists@xgm.de" target="_blank">mailinglists@xgm.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hello,<br>
<br>
I have this code to draw the structure of a matrix:<br>
<br>
PetscErrorCode ierr;<br>
PetscViewer viewer;<br>
ierr = PetscViewerCreate(communicator, &viewer); CHKERRV(ierr);<br>
ierr = PetscViewerSetType(viewer, PETSCVIEWERDRAW); CHKERRV(ierr);<br>
ierr = MatView(matrix, viewer); CHKERRV(ierr);<br>
ierr = PetscViewerDestroy(&viewer); CHKERRV(ierr);<br>
<br>
The window just opens for a fraction of a second and closes again. How can I keep it open until the user closes it?<br>
<br>
-draw_pause -1 seems to do the trick, but I don't want to use a command line option every time.<br>
<br>
PetscDrawSetPause(PetscDraw draw,PetscReal lpause) and PetscDrawPause both need a PetscDraw object. Where do I get this from?<br></blockquote><div><br></div><div><a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerDrawGetDraw.html#PetscViewerDrawGetDraw">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerDrawGetDraw.html#PetscViewerDrawGetDraw</a><br></div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Best,<br>
Florian<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div>
</div></div>