I am using pyqgis to create map automatically. However I encounter a problem when I want to set the grid annotation direction to 'Vertical Descending'. The command I use is the following:
composerMap.setGridAnnotationPosition(QgsComposerMap.OutsideMapFrame, \ QgsComposerMap.Top) composerMap.setGridAnnotationDirection(QgsComposerMap.VerticalDescending, \ QgsComposerMap.Top)
However, I get the following attribute error:
QgsComposerMap has no attributes VerticalDescending
After looking online, I found that this method is deprecated (https://qgis.org/api/deprecated.html) and that I should use grid() or grids() instead. When I look at qgscomposermapgrid.h source code (https://qgis.org/api/qgscomposermapgrid_8h_source.html#l00211) I see that there is an attribute 'VerticalDescending' (line 215) but I cannot find any example on how to use this method.