:orphan:
# PetscDrawAxisSetLabels
Sets the x and y axis labels. 
## Synopsis
```
#include "petscdraw.h"  
PetscErrorCode PetscDrawAxisSetLabels(PetscDrawAxis axis, const char top[], const char xlabel[], const char ylabel[])
```
Logically Collective


## Input Parameters

- ***axis -*** the axis
- ***top -*** the label at the top of the image
- ***xlabel,ylabel -*** the labes for the x and y axis





## Notes
Must be called before `PetscDrawAxisDraw()` or `PetscDrawLGDraw()`

There should be no newlines in the arguments


## See Also
 `PetscDraw`, `PetscDrawAxisCreate()`, `PetscDrawAxis`, `PetscDrawAxisSetColors()`, `PetscDrawAxisDraw()`, `PetscDrawAxisSetLimits()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/classes/draw/utils/axisc.c.html#PetscDrawAxisSetLabels">src/sys/classes/draw/utils/axisc.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/tutorials/ex68.c.html">src/ksp/ksp/tutorials/ex68.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/tutorials/ex69.c.html">src/ksp/ksp/tutorials/ex69.c</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/classes/draw/utils/axisc.c)


[Index of all Draw routines](index.md)  
[Table of Contents for all manual pages](/manualpages/index.md)  
[Index of all manual pages](/manualpages/singleindex.md)  
