From: <hee...@us...> - 2009-03-02 13:12:29
|
Revision: 1641 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1641&view=rev Author: heeroyuy Date: 2009-03-02 13:12:26 +0000 (Mon, 02 Mar 2009) Log Message: ----------- -fixed option panel Modified Paths: -------------- trunk/src/dl-learner/org/dllearner/tools/protege/DLLearnerView.java trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java trunk/src/dl-learner/org/dllearner/tools/protege/PosAndNegSelectPanel.java Modified: trunk/src/dl-learner/org/dllearner/tools/protege/DLLearnerView.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/protege/DLLearnerView.java 2009-03-02 11:17:08 UTC (rev 1640) +++ trunk/src/dl-learner/org/dllearner/tools/protege/DLLearnerView.java 2009-03-02 13:12:26 UTC (rev 1641) @@ -114,14 +114,16 @@ */ public DLLearnerView(String label, OWLEditorKit editor) { editorKit = editor; + model = new DLLearnerModel(editorKit, label, this); + sugPanel = new SuggestClassPanel(); + action = new ActionHandler(this.action, model, this, label); + readThread = new ReadingOntologyThread(editorKit, null, this, model); + readThread.start(); wikiPane = new JLabel("<html>See <a href=\"http://dl-learner.org/wiki/ProtegePlugin\">http://dl-learner.org/wiki/ProtegePlugin</a> for an introduction.</html>"); URL iconUrl = this.getClass().getResource("arrow.gif"); icon = new ImageIcon(iconUrl); URL toggledIconUrl = this.getClass().getResource("arrow2.gif"); toggledIcon = new ImageIcon(toggledIconUrl); - model = new DLLearnerModel(editorKit, label, this); - sugPanel = new SuggestClassPanel(); - action = new ActionHandler(this.action, model, this, label); adv = new JLabel("Advanced Settings"); advanced = new JToggleButton(icon); advanced.setVisible(true); @@ -148,8 +150,6 @@ model.clearVector(); hint.setText("To get suggestions for class descriptions, please click the button above."); isInconsistent = false; - readThread = new ReadingOntologyThread(editorKit, null, this, model); - readThread.start(); hint.setVisible(true); advanced.setIcon(icon); @@ -277,7 +277,6 @@ model.unsetNewConcepts(); action.destroyDLLearnerThread(); errorMessage.setText(""); - //posPanel.unsetPosAndNegPanel(); learner.removeAll(); } Modified: trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java 2009-03-02 11:17:08 UTC (rev 1640) +++ trunk/src/dl-learner/org/dllearner/tools/protege/OptionPanel.java 2009-03-02 13:12:26 UTC (rev 1641) @@ -20,7 +20,6 @@ package org.dllearner.tools.protege; import java.awt.Dimension; -import java.awt.GridLayout; import javax.swing.JLabel; import javax.swing.JPanel; @@ -40,25 +39,26 @@ private final JSlider minAccuracy; private final JSlider maxExecutionTime; private final JSlider nrOfConcepts; - private final JPanel optionPanel; private double accuracy; /** - * Construktor for the Option Panel. + * Constructor for the Option Panel. */ public OptionPanel() { - - setPreferredSize(new Dimension(490, 120)); - setLayout(new GridLayout(0, 1)); - optionPanel = new JPanel(new GridLayout(0, 2)); + setPreferredSize(new Dimension(490, 100)); + setLayout(null); minAccuracyLabel = new JLabel("minimum accuracy"); + minAccuracyLabel.setBounds(5, 0, 150, 40); maxExecutionTimeLabel = new JLabel("maximum execution time"); + maxExecutionTimeLabel.setBounds(5, 40, 150, 40); nrOfConceptsLabel = new JLabel("maximum number of results"); + nrOfConceptsLabel.setBounds(5, 80, 150, 40); minAccuracy = new JSlider(50, 100, 90); minAccuracy.setPaintTicks(true); minAccuracy.setMajorTickSpacing(10); minAccuracy.setMinorTickSpacing(1); minAccuracy.setPaintLabels(true); + minAccuracy.setBounds(160, 0, 200, 40); maxExecutionTime = new JSlider(2, 20, 5); @@ -66,6 +66,7 @@ maxExecutionTime.setMajorTickSpacing(5); maxExecutionTime.setMinorTickSpacing(1); maxExecutionTime.setPaintLabels(true); + maxExecutionTime.setBounds(160, 40, 200, 40); nrOfConcepts = new JSlider(2, 20, 10); @@ -73,15 +74,14 @@ nrOfConcepts.setMajorTickSpacing(2); nrOfConcepts.setMinorTickSpacing(1); nrOfConcepts.setPaintLabels(true); + nrOfConcepts.setBounds(160, 80, 200, 40); - optionPanel.add(minAccuracyLabel); - optionPanel.add(minAccuracy); - optionPanel.add(maxExecutionTimeLabel); - optionPanel.add(maxExecutionTime); - optionPanel.add(nrOfConceptsLabel); - optionPanel.add(nrOfConcepts); - add(optionPanel); - + add(minAccuracyLabel); + add(minAccuracy); + add(maxExecutionTimeLabel); + add(maxExecutionTime); + add(nrOfConceptsLabel); + add(nrOfConcepts); } /** Modified: trunk/src/dl-learner/org/dllearner/tools/protege/PosAndNegSelectPanel.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/protege/PosAndNegSelectPanel.java 2009-03-02 11:17:08 UTC (rev 1640) +++ trunk/src/dl-learner/org/dllearner/tools/protege/PosAndNegSelectPanel.java 2009-03-02 13:12:26 UTC (rev 1641) @@ -102,7 +102,7 @@ //set layout for parent Panel super(); setLayout(new GridLayout(0, 1)); - setPreferredSize(new Dimension(490, 250)); + setPreferredSize(new Dimension(490, 100)); //view = v; //this.model = model; //handler = new PosAndNegSelectPanelHandler(model, view, this); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |