- Timestamp:
- 2008-08-31T13:43:29+12:00 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gli/trunk/src/org/greenstone/gatherer/cdm/IndexOptionManager.java
r13468 r17114 190 190 private JCheckBox casefold_checkbox = new JCheckBox(); 191 191 private JCheckBox accentfold_checkbox = new JCheckBox(); 192 192 private JCheckBox separate_cjk_checkbox =new JCheckBox(); 193 193 194 public StemmingControl() 194 195 { … … 197 198 198 199 stem_checkbox.setText(Dictionary.get("CDM.IndexingManager.Stem")); 200 stem_checkbox.setToolTipText(Dictionary.get("CDM.IndexingManager.Stem_Tooltip")); 199 201 stem_checkbox.setActionCommand(StaticStrings.STEM_OPTION_STR); 200 202 201 203 casefold_checkbox.setText(Dictionary.get("CDM.IndexingManager.Casefold")); 204 casefold_checkbox.setToolTipText(Dictionary.get("CDM.IndexingManager.Casefold_Tooltip")); 202 205 casefold_checkbox.setActionCommand(StaticStrings.CASEFOLD_OPTION_STR); 203 206 204 207 accentfold_checkbox.setText(Dictionary.get("CDM.IndexingManager.Accent_fold")); 208 accentfold_checkbox.setToolTipText(Dictionary.get("CDM.IndexingManager.Accent_fold_Tooltip")); 205 209 accentfold_checkbox.setActionCommand(StaticStrings.ACCENTFOLD_OPTION_STR); 206 210 // Accent-folding is currently not available for MG 207 211 accentfold_checkbox.setEnabled(!build_type.equals(BuildTypeManager.BUILD_TYPE_MG)); 208 212 213 separate_cjk_checkbox.setText(Dictionary.get("CDM.IndexingManager.Separate_cjk")); 214 separate_cjk_checkbox.setToolTipText(Dictionary.get("CDM.IndexingManager.Separate_cjk_Tooltip")); 215 separate_cjk_checkbox.setActionCommand(StaticStrings.SEPARATE_CJK_OPTION_STR); 216 209 217 JPanel checkbox_panel = new JPanel(); 210 checkbox_panel.setLayout(new GridLayout(1, 3)); 211 checkbox_panel.add(stem_checkbox); 212 checkbox_panel.add(casefold_checkbox); 213 checkbox_panel.add(accentfold_checkbox); 214 218 checkbox_panel.setLayout(new GridLayout(2, 1)); 219 220 JPanel stem_panel = new JPanel(); 221 stem_panel.setLayout(new GridLayout(1,3)); 222 stem_panel.add(stem_checkbox); 223 stem_panel.add(casefold_checkbox); 224 stem_panel.add(accentfold_checkbox); 225 226 JPanel other_panel = new JPanel(); 227 other_panel.setLayout(new GridLayout(1,1)); 228 other_panel.add(separate_cjk_checkbox); 229 230 checkbox_panel.add(stem_panel); 231 checkbox_panel.add(other_panel); 232 215 233 add(new JLabel(Dictionary.get("CDM.IndexingManager.Options")), BorderLayout.WEST); 216 234 add(checkbox_panel, BorderLayout.CENTER); … … 227 245 stem_model.addOption(StaticStrings.ACCENTFOLD_OPTION_STR); 228 246 } 247 separate_cjk_checkbox.setSelected(false); 229 248 } 230 249 else { … … 238 257 accentfold_checkbox.setSelected(true); 239 258 } 259 if (stem_model.getOption(StaticStrings.SEPARATE_CJK_OPTION_STR) != null) { 260 separate_cjk_checkbox.setSelected(true); 261 } 262 240 263 241 264 } … … 245 268 casefold_checkbox.addActionListener(cbl); 246 269 accentfold_checkbox.addActionListener(cbl); 247 270 separate_cjk_checkbox.addActionListener(cbl); 271 248 272 // changing stem indexes changes build settings 249 273 stem_checkbox.addActionListener(CollectionDesignManager.buildcol_change_listener); 250 274 casefold_checkbox.addActionListener(CollectionDesignManager.buildcol_change_listener); 251 275 accentfold_checkbox.addActionListener(CollectionDesignManager.buildcol_change_listener); 252 276 separate_cjk_checkbox.addActionListener(CollectionDesignManager.buildcol_change_listener); 253 277 254 278 } … … 258 282 if (new_build_type.equals(BuildTypeManager.BUILD_TYPE_MG)) { 259 283 //changing to MG 284 accentfold_checkbox.setSelected(false); 260 285 accentfold_checkbox.setEnabled(false); 261 286 if (accentfold_checkbox.isSelected()) {
Note:
See TracChangeset
for help on using the changeset viewer.