Commit 2ed5197a authored by tu's avatar tu

changed typesystem, added lsergel to names, deleted tvalta from names,

deleted border feel
parent b93295e8
Pipeline #10627 passed with stage
in 4 minutes and 36 seconds
...@@ -1840,9 +1840,6 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart { ...@@ -1840,9 +1840,6 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart {
borderValue = STATE; borderValue = STATE;
break; break;
case STATE: case STATE:
borderValue = FEEL;
break;
case FEEL:
borderValue = UNSPEC; borderValue = UNSPEC;
break; break;
default: default:
...@@ -1939,10 +1936,6 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart { ...@@ -1939,10 +1936,6 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart {
nameFeatString = "ttu"; nameFeatString = "ttu";
rwMetadataDialog.ttuFlag = false; rwMetadataDialog.ttuFlag = false;
} else if (rwMetadataDialog.tvaltaFlag == true) {
nameFeatString = "tvalta";
rwMetadataDialog.tvaltaFlag = false;
} else if (rwMetadataDialog.ahartmannFlag == true) { } else if (rwMetadataDialog.ahartmannFlag == true) {
nameFeatString = "ahartmann"; nameFeatString = "ahartmann";
rwMetadataDialog.ahartmannFlag = false; rwMetadataDialog.ahartmannFlag = false;
...@@ -1951,6 +1944,10 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart { ...@@ -1951,6 +1944,10 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart {
nameFeatString = "lschaefer"; nameFeatString = "lschaefer";
rwMetadataDialog.lschaeferFlag = false; rwMetadataDialog.lschaeferFlag = false;
} else if (rwMetadataDialog.lsergelFlag == true) {
nameFeatString = "lsergel";
rwMetadataDialog.lsergelFlag = false;
/* /*
} else { } else {
...@@ -1967,7 +1964,7 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart { ...@@ -1967,7 +1964,7 @@ public class RedeWiedergabeView extends AEditorSubordinateViewPart {
updateAnnotation(metaDataList.get(0), timeStampFeat, timestampValue, true); updateAnnotation(metaDataList.get(0), timeStampFeat, timestampValue, true);
String versionValue = metaDataList.get(0).getFeatureValueAsString(versionFeat); String versionValue = metaDataList.get(0).getFeatureValueAsString(versionFeat);
versionValue = "0.0.8_1a 0.0.1s"; versionValue = "0.0.9_1a 0.0.1s";
//versionValue = "0.0.8a 0.0.1s"; //versionValue = "0.0.8a 0.0.1s";
updateAnnotation(metaDataList.get(0), versionFeat, versionValue, true); updateAnnotation(metaDataList.get(0), versionFeat, versionValue, true);
} }
......
...@@ -15,8 +15,7 @@ import javax.swing.JLabel; ...@@ -15,8 +15,7 @@ import javax.swing.JLabel;
import javax.swing.JPanel; import javax.swing.JPanel;
import javax.swing.JTextField; import javax.swing.JTextField;
import javax.swing.SwingUtilities; import javax.swing.SwingUtilities;
import javax.swing.UIManager;
import javax.swing.text.DefaultCaret;
import de.ids.tt.athen.rwview.part.RedeWiedergabeView; import de.ids.tt.athen.rwview.part.RedeWiedergabeView;
...@@ -24,13 +23,13 @@ public class EditMetadataDialog extends JFrame implements ActionListener { ...@@ -24,13 +23,13 @@ public class EditMetadataDialog extends JFrame implements ActionListener {
static RedeWiedergabeView part; static RedeWiedergabeView part;
private JComboBox<String> titleComboBox; private JTextField titleField = new JTextField(20);
private JComboBox<String> authorComboBox; private JTextField authorField = new JTextField(20);
private Color thistle = new Color(216,191,216); private Color thistle = new Color(216,191,216);
private String corpuspartArray [] = {"not defined", "famz", "erz", "zeit"}; private String corpuspartArray [] = {"not defined", "famz", "erz", "zeit"};
private JComboBox<String> corpuspartComboBox = new JComboBox<String>(corpuspartArray); private JComboBox<String> corpuspartComboBox= new JComboBox<String>(corpuspartArray);
private String fictionalArray [] = {"not defined", "yes", "no", "unsure"}; private String fictionalArray [] = {"not defined", "yes", "no", "unsure"};
private JComboBox<String> fictionalComboBox = new JComboBox<String>(fictionalArray); private JComboBox<String> fictionalComboBox = new JComboBox<String>(fictionalArray);
...@@ -67,31 +66,24 @@ public class EditMetadataDialog extends JFrame implements ActionListener { ...@@ -67,31 +66,24 @@ public class EditMetadataDialog extends JFrame implements ActionListener {
constraints.gridx = 1; constraints.gridx = 1;
if (label.getText().equals("Title")){ if (label.getText().equals("Title")){
String titleArray[] = {metadataVal.get(i)}; panel.add(titleField, constraints);
titleComboBox = new JComboBox<String>(titleArray); titleField.setText(metadataVal.get(i));
panel.add(titleComboBox, constraints);
titleComboBox.setSelectedItem(metadataVal.get(i));
titleComboBox.setEditable(true);
} }
if (label.getText().equals("Author")){ if (label.getText().equals("Author")){
String authorArray[] = {metadataVal.get(i)}; panel.add(authorField, constraints);
authorComboBox = new JComboBox<String>(authorArray); authorField.setText(metadataVal.get(i));
panel.add(authorComboBox, constraints);
authorComboBox.setSelectedItem(metadataVal.get(i));
authorComboBox.setEditable(true);
} }
if (label.getText().equals("Id") || label.getText().equals("OrigFile") || label.getText().equals("Year") || label.getText().equals("Decade") if (label.getText().equals("Id") || label.getText().equals("OrigFile") || label.getText().equals("Year") || label.getText().equals("Decade")
|| label.getText().equals("Textlength") || label.getText().equals("SampleID") || label.getText().equals("Periodical") || || label.getText().equals("Textlength") || label.getText().equals("SampleID") || label.getText().equals("Periodical") ||
label.getText().equals("Name") || label.getText().equals("Timestamp") || label.getText().equals("Version")) label.getText().equals("Name") || label.getText().equals("Timestamp") || label.getText().equals("Version"))
{ {
String valueArray[] = {metadataVal.get(i)}; JTextField field = new JTextField(20);
JComboBox<String> comboBox = new JComboBox<String>(valueArray); panel.add(field, constraints);
panel.add(comboBox, constraints); field.setText(metadataVal.get(i));
comboBox.setSelectedItem(metadataVal.get(i)); field.setEditable(false);
comboBox.setEditable(false); field.setBackground(thistle);
comboBox.setBackground(thistle);
} }
else if (label.getText().equals("Corpuspart")){ else if (label.getText().equals("Corpuspart")){
...@@ -131,7 +123,16 @@ public class EditMetadataDialog extends JFrame implements ActionListener { ...@@ -131,7 +123,16 @@ public class EditMetadataDialog extends JFrame implements ActionListener {
narrativeComboBox.setSelectedItem(narrativeArray[0]); narrativeComboBox.setSelectedItem(narrativeArray[0]);
} }
} }
} }
/*
else if (label.getText().equals("title") || label.getText().equals("Author")){
JTextField field = new JTextField(50);
field.setText(metadataVal.get(i));
panel.add(field, constraints);
}
*/
} }
constraints.gridx = 0; constraints.gridx = 0;
...@@ -170,9 +171,9 @@ public class EditMetadataDialog extends JFrame implements ActionListener { ...@@ -170,9 +171,9 @@ public class EditMetadataDialog extends JFrame implements ActionListener {
@Override @Override
public void actionPerformed(ActionEvent e) { public void actionPerformed(ActionEvent e) {
String titleInput = titleComboBox.getSelectedItem().toString(); String titleInput = titleField.getText();
part.setTitleInput(titleInput); part.setTitleInput(titleInput);
String authorInput = authorComboBox.getSelectedItem().toString(); String authorInput = authorField.getText();
part.setAuthorInput(authorInput); part.setAuthorInput(authorInput);
String corpuspartInput = corpuspartComboBox.getSelectedItem().toString(); String corpuspartInput = corpuspartComboBox.getSelectedItem().toString();
part.setCorpuspartInput(corpuspartInput); part.setCorpuspartInput(corpuspartInput);
......
...@@ -21,10 +21,11 @@ public class RwMetadataDialog extends Dialog { ...@@ -21,10 +21,11 @@ public class RwMetadataDialog extends Dialog {
public boolean abrunnerFlag = false; public boolean abrunnerFlag = false;
public boolean cpeterekFlag = false; public boolean cpeterekFlag = false;
public boolean lweimerFlag = false; public boolean lweimerFlag = false;
public boolean tvaltaFlag = false;
public boolean ttuFlag = false; public boolean ttuFlag = false;
public boolean ahartmannFlag = false; public boolean ahartmannFlag = false;
public boolean lschaeferFlag = false; public boolean lschaeferFlag = false;
public boolean lsergelFlag = false;
public RwMetadataDialog(Shell parentShell) { public RwMetadataDialog(Shell parentShell) {
super(parentShell); super(parentShell);
...@@ -50,9 +51,9 @@ public class RwMetadataDialog extends Dialog { ...@@ -50,9 +51,9 @@ public class RwMetadataDialog extends Dialog {
cpeterekFlag = false; cpeterekFlag = false;
lweimerFlag = false; lweimerFlag = false;
ttuFlag = false; ttuFlag = false;
tvaltaFlag = false;
ahartmannFlag = false; ahartmannFlag = false;
lschaeferFlag = false; lschaeferFlag = false;
lsergelFlag = false;
close(); close();
} }
else else
...@@ -78,9 +79,9 @@ public class RwMetadataDialog extends Dialog { ...@@ -78,9 +79,9 @@ public class RwMetadataDialog extends Dialog {
abrunnerFlag = false; abrunnerFlag = false;
lweimerFlag = false; lweimerFlag = false;
ttuFlag = false; ttuFlag = false;
tvaltaFlag = false;
ahartmannFlag = false; ahartmannFlag = false;
lschaeferFlag = false; lschaeferFlag = false;
lsergelFlag = false;
close(); close();
} }
else else
...@@ -105,9 +106,9 @@ public class RwMetadataDialog extends Dialog { ...@@ -105,9 +106,9 @@ public class RwMetadataDialog extends Dialog {
abrunnerFlag = false; abrunnerFlag = false;
cpeterekFlag = false; cpeterekFlag = false;
ttuFlag = false; ttuFlag = false;
tvaltaFlag = false;
ahartmannFlag = false; ahartmannFlag = false;
lschaeferFlag = false; lschaeferFlag = false;
lsergelFlag = false;
close(); close();
} }
else else
...@@ -133,9 +134,9 @@ public class RwMetadataDialog extends Dialog { ...@@ -133,9 +134,9 @@ public class RwMetadataDialog extends Dialog {
abrunnerFlag = false; abrunnerFlag = false;
cpeterekFlag = false; cpeterekFlag = false;
lweimerFlag = false; lweimerFlag = false;
tvaltaFlag = false;
ahartmannFlag = false; ahartmannFlag = false;
lschaeferFlag = false; lschaeferFlag = false;
lsergelFlag = false;
close(); close();
} }
else else
...@@ -146,84 +147,84 @@ public class RwMetadataDialog extends Dialog { ...@@ -146,84 +147,84 @@ public class RwMetadataDialog extends Dialog {
} }
}); });
final Button TVALTA = new Button(container, SWT.PUSH);
TVALTA.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false)); final Button AHARTMANN = new Button(container, SWT.PUSH);
TVALTA.setBackground(new Color (device, 220,20,60)); AHARTMANN.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false));
TVALTA.setText("tvalta"); AHARTMANN.setBackground(new Color (device, 100,149,237));
AHARTMANN.setText("ahartmann");
TVALTA.addSelectionListener(new SelectionAdapter() { AHARTMANN.addSelectionListener(new SelectionAdapter() {
@Override @Override
public void widgetSelected(SelectionEvent e) public void widgetSelected(SelectionEvent e)
{ {
if (TVALTA.getEnabled() == true) if (AHARTMANN.getEnabled() == true)
{ {
tvaltaFlag = true; ahartmannFlag = true;
abrunnerFlag = false; abrunnerFlag = false;
cpeterekFlag = false; cpeterekFlag = false;
lweimerFlag = false; lweimerFlag = false;
ttuFlag = false; ttuFlag = false;
ahartmannFlag = false;
lschaeferFlag = false; lschaeferFlag = false;
lsergelFlag = false;
close(); close();
} }
else else
{ {
tvaltaFlag = false; ahartmannFlag = false;
} }
} }
}); });
final Button LSCHAEFER = new Button(container, SWT.PUSH);
LSCHAEFER.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false));
LSCHAEFER.setBackground(new Color (device, 255,215,0));
LSCHAEFER.setText("lschaefer");
final Button AHARTMANN = new Button(container, SWT.PUSH); LSCHAEFER.addSelectionListener(new SelectionAdapter() {
AHARTMANN.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false));
AHARTMANN.setBackground(new Color (device, 100,149,237));
AHARTMANN.setText("ahartmann");
AHARTMANN.addSelectionListener(new SelectionAdapter() {
@Override @Override
public void widgetSelected(SelectionEvent e) public void widgetSelected(SelectionEvent e)
{ {
if (AHARTMANN.getEnabled() == true) if (LSCHAEFER.getEnabled() == true)
{ {
ahartmannFlag = true; lschaeferFlag = true;
abrunnerFlag = false; abrunnerFlag = false;
ahartmannFlag = false;
cpeterekFlag = false; cpeterekFlag = false;
lweimerFlag = false; lweimerFlag = false;
ttuFlag = false; ttuFlag = false;
tvaltaFlag = false; lsergelFlag = false;
lschaeferFlag = false;
close(); close();
} }
else else
{ {
ahartmannFlag = false; lschaeferFlag = false;
} }
} }
}); });
final Button LSCHAEFER = new Button(container, SWT.PUSH); final Button LSERGEL = new Button(container, SWT.PUSH);
LSCHAEFER.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false)); LSERGEL.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false));
LSCHAEFER.setBackground(new Color (device, 255,215,0)); LSERGEL.setBackground(new Color (device, 220,20,60));
LSCHAEFER.setText("lschaefer"); LSERGEL.setText("lsergel");
LSCHAEFER.addSelectionListener(new SelectionAdapter() { LSERGEL.addSelectionListener(new SelectionAdapter() {
@Override @Override
public void widgetSelected(SelectionEvent e) public void widgetSelected(SelectionEvent e)
{ {
if (LSCHAEFER.getEnabled() == true) if (LSERGEL.getEnabled() == true)
{ {
lschaeferFlag = true; lsergelFlag = true;
lschaeferFlag = false;
abrunnerFlag = false; abrunnerFlag = false;
ahartmannFlag = false; ahartmannFlag = false;
cpeterekFlag = false; cpeterekFlag = false;
lweimerFlag = false; lweimerFlag = false;
ttuFlag = false; ttuFlag = false;
tvaltaFlag = false;
close(); close();
} }
else else
{ {
lschaeferFlag = false; lsergelFlag = false;
} }
} }
}); });
......
...@@ -5,9 +5,7 @@ ...@@ -5,9 +5,7 @@
<description/> <description/>
<version>1.0</version> <version>1.0</version>
<vendor/> <vendor/>
<imports> <types>
</imports>
<types>
<typeDescription> <typeDescription>
<name>de.idsma.rw.Metadata</name> <name>de.idsma.rw.Metadata</name>
<description/> <description/>
...@@ -688,7 +686,7 @@ ...@@ -688,7 +686,7 @@
<typeDescription> <typeDescription>
<name>de.idsma.rw.CabToken</name> <name>de.idsma.rw.CabToken</name>
<description/> <description>CAB tokenizer</description>
<supertypeName>uima.tcas.Annotation</supertypeName> <supertypeName>uima.tcas.Annotation</supertypeName>
<features> <features>
<featureDescription> <featureDescription>
...@@ -716,6 +714,11 @@ ...@@ -716,6 +714,11 @@
<description/> <description/>
<rangeTypeName>uima.cas.String</rangeTypeName> <rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription> </featureDescription>
<featureDescription>
<name>RfPos</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
</features> </features>
</typeDescription> </typeDescription>
...@@ -749,5 +752,79 @@ ...@@ -749,5 +752,79 @@
</typeDescription> </typeDescription>
<typeDescription>
<name>de.idsma.rw.preprocessing.Token</name>
<description>openNLPTokenizer</description>
<supertypeName>uima.tcas.Annotation</supertypeName>
<features>
<featureDescription>
<name>Lemma</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>RFPos</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
</features>
</typeDescription>
<typeDescription>
<name>de.idsma.rw.preprocessing.OpenNLPCabSentence</name>
<description>OpenNLP sentence detector used for CABToken</description>
<supertypeName>uima.tcas.Annotation</supertypeName>
</typeDescription>
<typeDescription>
<name>de.idsma.rw.AutoStwr</name>
<description>Stwr annotations created by a rule-based function / machine learning</description>
<supertypeName>uima.tcas.Annotation</supertypeName>
<features>
<featureDescription>
<name>AutoMedium</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoRType</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoLevel</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoNonFact</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoPrag</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoBorder</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoMetaph</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoStwr</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
<featureDescription>
<name>AutoStwrID</name>
<description/>
<rangeTypeName>uima.cas.String</rangeTypeName>
</featureDescription>
</features>
</typeDescription>
</types>