Nevron Open Vision Documentation
Grid and Rulers
About Grid and Rulers

The grid and rulers settings of each page are exposed by the NGrid and NRulers elements, which are accessible from the Grid and Rulers properties of each NPage. Because the grid and rulers have many common aspects, the NGrid and NRulers classes derive from the base NGridRulersBase class that defines most of their common features.

The grid and rulers are designed to help the user better align and measure the content of the page. That is why it primary works in page Logical Units (see the Pages - Drawing Scale section for more info).

Origin and Step

The origin of the grid and rulers is the point from which the respective major lines originate. It is controlled by the OriginX and OriginY properties and is measured in the page Logical Units. By default it is set to 0.

Both the grid and rulers can have X and Y step mode, which defines the way in which the respective major step is defined. The XStepMode and YStepMode properties can take values of the ENStepMode enumeration:

Grid Appearance

The way in which the grid is displayed is controlled by the GridStyle property that accepts values from the ENGridStyle enumeration:

The MajorLinesStroke and MinorLinesStroke properties control the appearance of the major and minor gridlines respectively.

The HorizontalStripesColor and VerticalStripesColor properties control the filling of the horizontal and vertical stripes respectively. 

Rulers Appearance
The MinorTickCount property controls the number of minor ticks between major ones. The ValuesFormatter attribute controls the formatting of the ruler values.  


Send Feedback