Révision 4004
TXM/trunk/bundles/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesEditor.java (revision 4004) | ||
---|---|---|
37 | 37 |
import org.eclipse.swt.events.MouseEvent; |
38 | 38 |
import org.eclipse.swt.events.MouseListener; |
39 | 39 |
import org.eclipse.swt.layout.GridData; |
40 |
import org.eclipse.swt.widgets.Combo; |
|
40 | 41 |
import org.eclipse.swt.widgets.Composite; |
41 | 42 |
import org.eclipse.swt.widgets.Label; |
42 | 43 |
import org.eclipse.swt.widgets.ScrollBar; |
... | ... | |
127 | 128 |
* Maximum number of lines filtering. |
128 | 129 |
*/ |
129 | 130 |
@Parameter(key = SpecificitiesPreferences.CONTRAST_SCRIPT) |
130 |
protected Text modeText;
|
|
131 |
protected Combo modeText;
|
|
131 | 132 |
|
132 | 133 |
@Override |
133 | 134 |
public void _createPartControl() { |
... | ... | |
160 | 161 |
|
161 | 162 |
// change statistical computing |
162 | 163 |
if (TBXPreferences.getInstance().getBoolean(TBXPreferences.EXPERT_USER)) { |
163 |
modeText = new Text(extendedParametersArea, SWT.BORDER); // not yet ready |
|
164 |
|
|
165 |
new Label(extendedParametersArea, SWT.NONE).setText("Mode or R code or R script"); |
|
166 |
|
|
167 |
modeText = new Combo(extendedParametersArea, SWT.BORDER|SWT.SINGLE); // not yet ready |
|
168 |
modeText.setItems("specif", "relative", "apply(SYMBOL, 2, function(x) x / sum(x) * 100)"); |
|
164 | 169 |
} |
165 | 170 |
|
166 | 171 |
// Result area |
TXM/trunk/bundles/org.txm.rcp/src/main/java/org/txm/rcp/editors/TXMEditor.java (revision 4004) | ||
---|---|---|
1435 | 1435 |
else if (object instanceof Text) { |
1436 | 1436 |
((Text) object).setText(String.valueOf(value)); |
1437 | 1437 |
} |
1438 |
else if (object instanceof Combo) { |
|
1439 |
if (value instanceof String) { |
|
1440 |
((Combo) object).setText(String.valueOf(value)); |
|
1441 |
} |
|
1442 |
} |
|
1438 | 1443 |
else if (object instanceof StyledText) { |
1439 | 1444 |
((StyledText) object).setText(String.valueOf(value)); |
1440 | 1445 |
} |
... | ... | |
2273 | 2278 |
else if (object instanceof Text) { |
2274 | 2279 |
((Text) object).setText(String.valueOf(value)); |
2275 | 2280 |
} |
2281 |
else if (object instanceof Combo) { |
|
2282 |
if (value instanceof String) { |
|
2283 |
((Combo) object).setText(String.valueOf(value)); |
|
2284 |
} |
|
2285 |
} |
|
2276 | 2286 |
else if (object instanceof StyledText) { |
2277 | 2287 |
((StyledText) object).setText(String.valueOf(value)); |
2278 | 2288 |
} |
Formats disponibles : Unified diff