Свойство | Тип | Описание | |
---|---|---|---|
ConvertKeyValue | int | ||
GetCoordRects | void | ||
RotatePointDstToPaint | Point | ||
RotatePointPaintToDst | Point | ||
RotateRectDstToPaint |
Метод | Описание | |
---|---|---|
DrawTheRoot ( IVwDrawRootBuffered vdrb, IVwRootBox rootb, |
The core of the Draw() method, where the rectangle actually gets painted. Vertical views use a rotated drawing routine.
|
|
GetAvailWidth ( ) : int |
The width available for laying out a line of text, before subtracting margins. Normally this is the width of the pane, but for vertical alignment it is the height.
|
|
VerticalOrientationManager ( |
Constructor
|
Метод | Описание | |
---|---|---|
ConvertKeyValue ( int keyValue ) : int |
Convert arrow key codes so as to handle rotation (and line inversion). Enhance JohnT: possibly up/down inversion should be handled by the VwVerticalRootBox class, in which case, Up and Down results should be swapped here?
|
|
GetCoordRects ( |
Construct coord transformation rectangles. Height and width are dots per inch (swapped for rotation); src origin is 0, dest origin is controlled by scrolling. A change in the y value of rcDstRoot origin will move the view left or right. A zero position of the scroll bar puts the 'bottom' at the right of the window. We want instead to put the 'top' at the left of the window for offset zero, and move it to the left as the offset increases. Passing an actual offset of 0 puts the bottom of the view at the right of the window. Adding the rootbox height puts the top just out of sight beyond the right edge; subtracting the client rectangle puts it in the proper zero-offset position with the top just at the left of the window. Further subtracting the scroll offset moves it further right, or 'up'.
|
|
RotatePointDstToPaint ( Point pt ) : Point |
The specified point is in 'destination' coordinates. In a vertical view it requires rotation in the same way that the drawing code rotates the actual pixels drawn. This basically means that pt.Y is measured from the right of the window and pt.X is measured from the top. The result needs to be the same point in normal coordinates.
|
|
RotatePointPaintToDst ( Point pt ) : Point |
The specified point is in 'paint' coordinates. In a vertical view it requires rotation reversing way that the drawing code rotates the actual pixels drawn to get 'destination' coordinates that the root box will interpret correctly. This basically converts a normal point to one where X is measured from the top of the client rectangle and Y from the right.
|
|
RotateRectDstToPaint ( |
The specified rectangle is in 'destination' coordinates. In a vertical view it requires rotation in the same way that the drawing code rotates the actual pixels drawn. This basically means that the input is a rectangle whose top and bottom are distances from the right of the window and whose left and right are measured from the top of the window. We need to convert it to one measured from the top left.
|
public DrawTheRoot ( IVwDrawRootBuffered vdrb, IVwRootBox rootb, |
||
vdrb | IVwDrawRootBuffered | |
rootb | IVwRootBox | |
hdc | ||
drawRect | SIL | |
backColor | uint | |
drawSel | bool | |
clipRect | ||
Результат | void |
public VerticalOrientationManager ( |
||
site | ||
Результат | System |