summaryrefslogtreecommitdiff
path: root/inputmethods/dasher/DasherSettingsInterface.h
blob: 9d03ebaa559b6707d6c11477efe86369c019aa3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
// DasherSettingsInterface.h
//
/////////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2002 Iain Murray
//
/////////////////////////////////////////////////////////////////////////////


#ifndef __DasherSettingsInterface_h__
#define __DasherSettingsInterface_h__

#include "DasherTypes.h"
#include "SettingsStore.h"

namespace Dasher {class CDasherSettingsInterface;}
class Dasher::CDasherSettingsInterface
{
public:
	void SettingsDefaults(CSettingsStore* Store);
	
	// These actually affect the way Dasher works
	//! Change the alphabet in use to NewAlphabetID
	virtual void ChangeAlphabet(const std::string& NewAlphabetID) {};

	//! Change the maximum bitrate (effectively the speed) of Dasher
	virtual void ChangeMaxBitRate(double NewMaxBitRate) {};

	//! Generate a new langage model. Not usually needed
	virtual void ChangeLanguageModel(unsigned int NewLanguageModelID) {};

	//! Generate a new view of the model. Call it with 0 when starting up
	virtual void ChangeView(unsigned int NewViewID) {};

	//! Change the orientation (l->r, r->l, so on) of the model
	virtual void ChangeOrientation(Opts::ScreenOrientations Orientation) {};

	//! Set the file encoding of output files to Encoding
	virtual void SetFileEncoding(Opts::FileEncodingFormats Encoding) {};

	//! Inform the core that the screen has this size
	virtual void SetScreenSize(long Width, long Height) {};
	
	//! Set the size of the font used in the Dasher canvas
	virtual void SetDasherFontSize(Dasher::Opts::FontSize fontsize) {};

	//! Set the number of dimensions of input (either 1 or 2)
	virtual void SetDasherDimensions(bool Value) {};

	// These are recommended options for the Dasher GUI. {{{ They don't actually
	// change the way Dasher works. They are part of the Dasher interface
	// anyway so that it can handle option saving for you, and to make it
	// easy for the Dasher engine to control the GUI later on. }}}

	//! True if toolbar should be shown, false otherwise
	virtual void ShowToolbar(bool Value) {};

	//! True if toolbar should show text, false otherwse
	virtual void ShowToolbarText(bool Value) {};

	//! True if toolbar should have large icons, false otherwise
	virtual void ShowToolbarLargeIcons(bool Value) {};

	//! True if the speed slider should be shown, false otherwise
	virtual void ShowSpeedSlider(bool Value) {};

	//! True if the window layout should be fixed, false otherwise
	virtual void FixLayout(bool Value) {};

	//! True if new files should be timestamped, false otherwise
	virtual void TimeStampNewFiles(bool Value) {};

	//! True if all text should be copied to clipboard when Dasher is stopped, false otherwise
	virtual void CopyAllOnStop(bool Value) {};

	//! True if a box should be drawn to represent the logical position of the mouse
	virtual void DrawMouse(bool Value) {};

	//! Set the editbox font 
	virtual void SetEditFont(std::string Name, long Size) {};

	//! Set the canvas font
	virtual void SetDasherFont(std::string Name) {};

	//! Set the height of the edit box
	virtual void SetEditHeight(long Value) {};
	
	//! Should Dasher start and stop on space bar?
	virtual void StartOnSpace(bool Value) {};

	//! Should Dasher start and stop on left mouse button?
	virtual void StartOnLeft(bool Value) {};
	
	//! Should Dasher be keyboard controlled?
	virtual void KeyControl(bool Value) {};
	
	//! Should Dasher pause when the pointer leaves the window?
	virtual void WindowPause(bool Value) {};
};


#include <string>

namespace Dasher
{
namespace Keys
{
	// Standard Option strings. You are encouraged to use these constants.
	// -------------------------------------------------------------------
	
	// bool options
	extern const std::string TIME_STAMP;
	extern const std::string SHOW_TOOLBAR;
	extern const std::string SHOW_TOOLBAR_TEXT;
	extern const std::string SHOW_LARGE_ICONS;
	extern const std::string FIX_LAYOUT;
	extern const std::string SHOW_SLIDER;
	extern const std::string COPY_ALL_ON_STOP;
	extern const std::string DRAW_MOUSE;
	extern const std::string START_SPACE;
	extern const std::string START_MOUSE;
	extern const std::string KEY_CONTROL;
	extern const std::string WINDOW_PAUSE;
	// long options
	extern const std::string FILE_ENCODING;
	extern const std::string MAX_BITRATE_TIMES100;
	extern const std::string SCREEN_ORIENTATION;
	extern const std::string VIEW_ID;
	extern const std::string LANGUAGE_MODEL_ID;
	extern const std::string EDIT_FONT_SIZE;
	extern const std::string EDIT_HEIGHT;
	extern const std::string SCREEN_WIDTH;
	extern const std::string SCREEN_HEIGHT;
	extern const std::string DASHER_FONTSIZE;
	extern const std::string DASHER_DIMENSIONS;
	
	// string options
	extern const std::string ALPHABET_ID;
	extern const std::string DASHER_FONT;
	extern const std::string EDIT_FONT;
}
} // namespace Dasher


#endif /* #ifndef __DasherSettingsInterface_h__ */