diff --git a/trunk/.classpath b/trunk/.classpath index 1cf4af03..07ffbb30 100644 --- a/trunk/.classpath +++ b/trunk/.classpath @@ -42,7 +42,5 @@ - - diff --git a/trunk/SIPRPSoft/src/siprp/higiene/gestao/normalizacao/GerirNormalizacaoPanel.java b/trunk/SIPRPSoft/src/siprp/higiene/gestao/normalizacao/GerirNormalizacaoPanel.java index add4443a..aa9dc6f3 100644 --- a/trunk/SIPRPSoft/src/siprp/higiene/gestao/normalizacao/GerirNormalizacaoPanel.java +++ b/trunk/SIPRPSoft/src/siprp/higiene/gestao/normalizacao/GerirNormalizacaoPanel.java @@ -257,7 +257,7 @@ public class GerirNormalizacaoPanel extends JPanel implements LeafUIConstants, C } ); textCodigo.addCaretListener( this ); textAreaDescricao.addCaretListener( this ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( textAreaDescricao ); + SpellChecker.getInstance().attachSpellCheckToComponent( textAreaDescricao ); buttonPortuguesaCriar.addActionListener( new ActionListener() { @Override diff --git a/trunk/SIPRPSoft/src/siprp/higiene/gestao/riscos/GerirMedidaPanel.java b/trunk/SIPRPSoft/src/siprp/higiene/gestao/riscos/GerirMedidaPanel.java index c4673c32..7a9cf6d2 100644 --- a/trunk/SIPRPSoft/src/siprp/higiene/gestao/riscos/GerirMedidaPanel.java +++ b/trunk/SIPRPSoft/src/siprp/higiene/gestao/riscos/GerirMedidaPanel.java @@ -68,10 +68,10 @@ public class GerirMedidaPanel extends JPanel { fieldTextMedida.setWrapStyleWord( true ); fieldTextMedida.setLineWrap( true ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( fieldTextMedida ); + SpellChecker.getInstance().attachSpellCheckToComponent( fieldTextMedida ); fieldTextRequisitosLegais.setWrapStyleWord( true ); fieldTextRequisitosLegais.setLineWrap( true ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( fieldTextRequisitosLegais ); + SpellChecker.getInstance().attachSpellCheckToComponent( fieldTextRequisitosLegais ); scrollMedida.setHorizontalScrollBarPolicy( JScrollPane.HORIZONTAL_SCROLLBAR_NEVER ); scrollMedida.setVerticalScrollBarPolicy( JScrollPane.VERTICAL_SCROLLBAR_ALWAYS ); scrollRequesitos.setHorizontalScrollBarPolicy( JScrollPane.HORIZONTAL_SCROLLBAR_NEVER ); diff --git a/trunk/SIPRPSoft/src/siprp/higiene/relatorio/GerirMedidaRelatorioPanel.java b/trunk/SIPRPSoft/src/siprp/higiene/relatorio/GerirMedidaRelatorioPanel.java index 771b2b61..db433996 100644 --- a/trunk/SIPRPSoft/src/siprp/higiene/relatorio/GerirMedidaRelatorioPanel.java +++ b/trunk/SIPRPSoft/src/siprp/higiene/relatorio/GerirMedidaRelatorioPanel.java @@ -80,8 +80,8 @@ public class GerirMedidaRelatorioPanel extends JPanel fieldTextMedida.setLineWrap( true ); fieldTextRequisitosLegais.setWrapStyleWord( true ); fieldTextRequisitosLegais.setLineWrap( true ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( fieldTextRequisitosLegais ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( fieldTextMedida ); + SpellChecker.getInstance().attachSpellCheckToComponent( fieldTextRequisitosLegais ); + SpellChecker.getInstance().attachSpellCheckToComponent( fieldTextMedida ); scrollMedida.setHorizontalScrollBarPolicy( JScrollPane.HORIZONTAL_SCROLLBAR_NEVER ); scrollMedida.setVerticalScrollBarPolicy( JScrollPane.VERTICAL_SCROLLBAR_ALWAYS ); scrollRequesitos.setHorizontalScrollBarPolicy( JScrollPane.HORIZONTAL_SCROLLBAR_NEVER ); diff --git a/trunk/common/src/leaf/ui/LeafTextAreaEditor.java b/trunk/common/src/leaf/ui/LeafTextAreaEditor.java index 471e6387..6051d54c 100644 --- a/trunk/common/src/leaf/ui/LeafTextAreaEditor.java +++ b/trunk/common/src/leaf/ui/LeafTextAreaEditor.java @@ -82,7 +82,7 @@ public class LeafTextAreaEditor extends JPanel scroll.setVerticalScrollBarPolicy( JScrollPane.VERTICAL_SCROLLBAR_ALWAYS ); buttonSave.setMargin( new Insets(0,0,0,0) ); buttonRevert.setMargin( new Insets(0,0,0,0) ); - SpellChecker.getInstance().getSpellChecker().attachSpellCheckToComponent( fieldText ); + SpellChecker.getInstance().attachSpellCheckToComponent( fieldText ); } private void startupLayout( boolean textField ) diff --git a/trunk/common/src/siprp/SpellChecker.java b/trunk/common/src/siprp/SpellChecker.java index bd22e234..9c599386 100644 --- a/trunk/common/src/siprp/SpellChecker.java +++ b/trunk/common/src/siprp/SpellChecker.java @@ -1,7 +1,7 @@ package siprp; -import com.evolute.modules.spellchecker.EvoSpellChecker; -import com.evolute.modules.spellchecker.EvoSpellChecker.Dictionary; +import javax.swing.JTextArea; +import javax.swing.text.JTextComponent; public class SpellChecker @@ -9,11 +9,11 @@ public class SpellChecker private static SpellChecker instance = null; - private final EvoSpellChecker spellChecker; +// private final EvoSpellChecker spellChecker; private SpellChecker() { - this.spellChecker = new EvoSpellChecker( Dictionary.PT_PT ); +// this.spellChecker = new EvoSpellChecker( Dictionary.PT_PT ); } public static SpellChecker getInstance() @@ -24,10 +24,11 @@ public class SpellChecker } return instance; } - - public EvoSpellChecker getSpellChecker() + + public void attachSpellCheckToComponent( JTextComponent fieldTextMedida ) { - return spellChecker; + // TODO Auto-generated method stub +// spellChecker.attachSpellCheckToComponent( fieldTextMedida ) } }