summaryrefslogtreecommitdiffstats
path: root/kdejava/koala/org/kde/koala/KSpellConfig.java
blob: 57b018dd295466883ce6b14a445bc2bf02bfc10d (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
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
//Auto-generated by kalyptus. DO NOT EDIT.
package org.kde.koala;

import org.kde.qt.Qt;
import org.kde.qt.TQMetaObject;
import org.kde.qt.QtSupport;
import org.kde.qt.TQComboBox;
import java.util.ArrayList;
import org.kde.qt.TQWidget;
import org.kde.qt.TQWidget;

/**

 A configuration class/dialog for KSpell.
 It contains all of the options settings.The options are set to default
 values by the constructor and can be reset either by using the
 public interface or by using KSpellConfig as a widget in a dialog
 (or, preferably a tabbed dialog using KDialogBase) and letting
 the user change the settings. This way an application that uses
 KSpell can either rely on the default settings (in the simplest
 case), offer a dialog to configure KSpell, or offer a dialog to
 configure KSpell <em>for this app only</em> (in which case, the application
 should save the settings for use next time it is run).
 This last option might be useful in an email program, for example, where
 people may be writing in a language different from that used for
 writing papers in their word processor.
 See {@link KSpellConfigSignals} for signals emitted by KSpellConfig
		@author David Sweet <dsweet@kde.org>

		@short    A configuration class/dialog for KSpell.
		@see KSpell

*/
public class KSpellConfig extends TQWidget  {
	protected KSpellConfig(Class dummy){super((Class) null);}
	public static final int rdictlist = 3;
	public static final int rencoding = 4;
	public static final int rhelp = 6;

	public native TQMetaObject metaObject();
	public native String className();
	/**	
		 Constructs a KSpellConfig with default or custom settings.
			@param parent Parent of the widget.
			@param name Widget name.
			@param spellConfig Predefined configuration. If this parameter
		        is 0, a default configuration will be used.
			@param addHelpButton Enabled or hides a help button. See
		 activateHelp for more information.
			     		@short    Constructs a KSpellConfig with default or custom settings.
	*/
	public KSpellConfig(TQWidget parent, String name, KSpellConfig spellConfig, boolean addHelpButton) {
		super((Class) null);
		newKSpellConfig(parent,name,spellConfig,addHelpButton);
	}
	private native void newKSpellConfig(TQWidget parent, String name, KSpellConfig spellConfig, boolean addHelpButton);
	public KSpellConfig(TQWidget parent, String name, KSpellConfig spellConfig) {
		super((Class) null);
		newKSpellConfig(parent,name,spellConfig);
	}
	private native void newKSpellConfig(TQWidget parent, String name, KSpellConfig spellConfig);
	public KSpellConfig(TQWidget parent, String name) {
		super((Class) null);
		newKSpellConfig(parent,name);
	}
	private native void newKSpellConfig(TQWidget parent, String name);
	public KSpellConfig(TQWidget parent) {
		super((Class) null);
		newKSpellConfig(parent);
	}
	private native void newKSpellConfig(TQWidget parent);
	public KSpellConfig() {
		super((Class) null);
		newKSpellConfig();
	}
	private native void newKSpellConfig();
	public KSpellConfig(KSpellConfig arg1) {
		super((Class) null);
		newKSpellConfig(arg1);
	}
	private native void newKSpellConfig(KSpellConfig arg1);
	/**	
			 Fills <code>box</code> with the human readable, translated dictionary names and
		 selects the currently used dictionary (this will be the global 
		 dictionary if you call {@link #fillDicts} directly after the constructor).
		 If <code>dictionaries</code> isn't 0 then <code>dictionaries</code> will be filled with the
		 corresponding internal dictionary names that are necessary to set the
		 dictionary with {@link #setDictionary}.
			@param box Will be filled with the translated dictionary names.
			@param dictionaries Will be filled with the internal dictionary names.
			     		@short Get the translated dictionary names and, optionally, the   corresponding internal dictionary names.
	*/
	public native void fillDicts(TQComboBox box, String[] dictionaries);
	public native void fillDicts(TQComboBox box);
	/**	
			 The <code>_ignorelist</code> contains words you'd like KSpell
		 to ignore when it is spellchecking.  When you get a KSpellConfig
		 object back from KSpell (using KSpell.kcConfig()),
		 the <code>_ignorelist</code> contains whatever was put in by you plus
		 any words the user has chosen to ignore via the dialog box.
		 It may be useful to save this list with the document being
		 edited to facilitate tquicker future spellchecking.
		     		@short
	*/
	public native void setIgnoreList(String[] _ignorelist);
	/**	
		 The <code>_replaceAllList</code> contains word you like that replace
		 word. Be careful that this list contains word which is replaced
		 and new word.
		     		@short    The <code>_replaceAllList</code> contains word you like that replace  word.
	*/
	public native void setReplaceAllList(String[] _replaceAllList);
	/**	
		 Set an ISpell option.
			 If <code>true</code>, don't create root-affix combinations.
		     		@short    Set an ISpell option.
	*/
	public native void setNoRootAffix(boolean arg1);
	/**	
		 Set an ISpell option.
			 If <code>true</code>, treat run-together words a valid.
		     		@short    Set an ISpell option.
	*/
	public native void setRunTogether(boolean arg1);
	/**	
		 Set the name of the dictionary to use.
		     		@short    Set the name of the dictionary to use.
	*/
	public native void setDictionary(String qs);
	public native void setDictFromList(boolean dfl);
	/**	
			     		@short
	*/
	public native void setEncoding(int enctype);
	public native void setClient(int client);
	/**	
		 Options reading routines.
		     		@short    Options reading routines.
	*/
	public native boolean noRootAffix();
	public native boolean runTogether();
	public native String dictionary();
	public native boolean dictFromList();
	public native int encoding();
	public native ArrayList ignoreList();
	public native ArrayList replaceAllList();
	public native int client();
	/**	
		 Call this method before this class is deleted  if you want
		 the settings you have (or the user has) chosen to become the
		 global, default settings.
		     		@short    Call this method before this class is deleted  if you want  the settings you have (or the user has) chosen to become the  global, default settings.
	*/
	public native boolean writeGlobalSettings();
	public native boolean readGlobalSettings();
	/**	
		 Use this function to activate the help information for this
		 widget. The function is particulary useful if the help button is
		 not displayed as specified by the constructor. Normally you want
		 to hide the help button if this widget is embedded into a larger
		 dialog box that has its own help button. See kedit
		 (optiondialog.cpp) for an example
		     		@short    Use this function to activate the help information for this  widget.
	*/
	public native void activateHelp();
	protected native void fillInDialog();
	/**	
		 This takes a dictionary file name and provides both a language
		 abbreviation appropriate for the $LANG variable, and a
		 human-readable name.
			 It also truncates ".aff" at the end of fname.
			@param fname the dictionary name file (input)
			@param lname the language abbreviation, such as de for German (output)
			@param hname the human-readable name, such as Deutsch (output)
				@return true if <pre>lname.data()==$LANG</pre>
     
		@short    This takes a dictionary file name and provides both a language  abbreviation appropriate for the $LANG variable, and a  human-readable name.
	*/
	protected native boolean interpret(StringBuffer fname, StringBuffer lname, StringBuffer hname);
	/**	
		 Invokes the help documentation for tdespell
		     		@short    Invokes the help documentation for tdespell
	*/
	protected native void sHelp();
	protected native void sNoAff(boolean arg1);
	protected native void sRunTogether(boolean arg1);
	protected native void sDictionary(boolean arg1);
	protected native void sPathDictionary(boolean arg1);
	protected native void sSetDictionary(int arg1);
	protected native void sChangeEncoding(int arg1);
	protected native void sChangeClient(int arg1);
	/** Deletes the wrapped C++ instance */
	protected native void finalize() throws InternalError;
	/** Delete the wrapped C++ instance ahead of finalize() */
	public native void dispose();
	/** Has the wrapped C++ instance been deleted? */
	public native boolean isDisposed();
}