author | mickeyl <mickeyl> | 2003-09-27 11:29:26 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-09-27 11:29:26 (UTC) |
commit | 651b6c612db4e809c506973996f2580c4158ac3a (patch) (unidiff) | |
tree | 8c8edc86e4b206dd4542a6b556ad1a319d6698ab /inputmethods/dasher/DasherViewSquare.h | |
parent | d1a11b45e805fe7771ea05944757d767c3c4c8ea (diff) | |
download | opie-651b6c612db4e809c506973996f2580c4158ac3a.zip opie-651b6c612db4e809c506973996f2580c4158ac3a.tar.gz opie-651b6c612db4e809c506973996f2580c4158ac3a.tar.bz2 |
merge dasher which has been introduced in BRANCH first (wtf?) into HEAD
Diffstat (limited to 'inputmethods/dasher/DasherViewSquare.h') (more/less context) (show whitespace changes)
-rw-r--r-- | inputmethods/dasher/DasherViewSquare.h | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/inputmethods/dasher/DasherViewSquare.h b/inputmethods/dasher/DasherViewSquare.h new file mode 100644 index 0000000..5d689d0 --- a/dev/null +++ b/inputmethods/dasher/DasherViewSquare.h | |||
@@ -0,0 +1,58 @@ | |||
1 | // DasherViewSquare.h | ||
2 | // | ||
3 | ///////////////////////////////////////////////////////////////////////////// | ||
4 | // | ||
5 | // Copyright (c) 2001-2002 David Ward | ||
6 | // | ||
7 | ///////////////////////////////////////////////////////////////////////////// | ||
8 | |||
9 | #ifndef __DasherViewSquare_h__ | ||
10 | #define __DasherViewSquare_h__ | ||
11 | |||
12 | #include "MSVC_Unannoy.h" | ||
13 | #include "DasherScreen.h" | ||
14 | #include "DasherModel.h" | ||
15 | #include "DasherView.h" | ||
16 | |||
17 | |||
18 | // An implementation of the DasherView class | ||
19 | // | ||
20 | // This class renders Dasher in the vanilla style, | ||
21 | // but with horizontal and vertical mappings | ||
22 | // | ||
23 | // Horizontal mapping - linear and log | ||
24 | // Vertical mapping - linear with different gradient | ||
25 | |||
26 | namespace Dasher {class CDasherViewSquare;} | ||
27 | class Dasher::CDasherViewSquare : public Dasher::CDasherView | ||
28 | { | ||
29 | public: | ||
30 | CDasherViewSquare(CDasherScreen* DasherScreen, CDasherModel& DasherModel, Dasher::Opts::ScreenOrientations Orientation=Dasher::Opts::LeftToRight); | ||
31 | void TapOnDisplay(int mousex,int mousey, unsigned long Time); | ||
32 | |||
33 | void ChangeScreen(CDasherScreen* NewScreen); | ||
34 | void DrawMouse(int mousex, int mousey); | ||
35 | void DrawKeyboard(); | ||
36 | private: | ||
37 | // the x and y non-linearities | ||
38 | inline const void screen2dasher(int *mousex, int *mousey); | ||
39 | inline const int dasherx2screen(const myint sx); | ||
40 | inline const int dashery2screen(myint sy); | ||
41 | |||
42 | int RenderNode(const symbol Character, const int Color, Opts::ColorSchemes ColorScheme, | ||
43 | myint y1, myint y2, int& mostleft, bool& force, bool text); | ||
44 | |||
45 | void CheckForNewRoot(); | ||
46 | inline void Crosshair(myint sx); | ||
47 | double m_dXmpa,m_dXmpb,m_dXmpc,m_dXmpd; | ||
48 | myint m_Y1,m_Y2,m_Y3; | ||
49 | myint s_Y1,s_Y2,s_Y3; | ||
50 | int CanvasX,CanvasY,CanvasBorder; | ||
51 | double xmap(double x); | ||
52 | double ixmap(double x); | ||
53 | }; | ||
54 | |||
55 | #include "DasherViewSquare.inl" | ||
56 | |||
57 | |||
58 | #endif /* #ifndef __DasherViewSquare_h__ */ | ||