:orphan: # PetscViewerPushFormat Sets the format for a `PetscViewer`. ## Synopsis ``` #include "petscsys.h" PetscErrorCode PetscViewerPushFormat(PetscViewer viewer, PetscViewerFormat format) ``` Logically Collective ## Input Parameters - ***viewer -*** the `PetscViewer` - ***format -*** the format ## Note See `PetscViewerFormat` for available values ## See Also [](sec_viewers), `PetscViewer`, `PetscViewerFormat`, `PetscViewerASCIIOpen()`, `PetscViewerBinaryOpen()`, `MatView()`, `VecView()`, `PetscViewerSetFormat()`, `PetscViewerPopFormat()` ## Level intermediate ## Location src/sys/classes/viewer/interface/viewa.c ## Examples src/dm/impls/plex/tutorials/ex5.c
src/dm/tutorials/ex22.c
src/dm/tutorials/ex7.c
src/ksp/ksp/tutorials/ex27.c
src/ksp/ksp/tutorials/ex34.c
src/ksp/ksp/tutorials/ex54.c
src/ksp/ksp/tutorials/ex55.c
src/ksp/ksp/tutorials/ex56.c
src/mat/tutorials/ex10.c
src/snes/tutorials/ex17.c
src/snes/tutorials/ex1f.F90
--- [Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/classes/viewer/interface/viewa.c) [Index of all Viewer routines](index.md) [Table of Contents for all manual pages](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)