Package org.omegat.gui.editor
Class EditorSettings
java.lang.Object
org.omegat.gui.editor.EditorSettings
- All Implemented Interfaces:
IEditorSettings
Editor behavior control settings.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionchargetAttributeSet(boolean isSource, boolean isPlaceholder, boolean isRemoveText, SourceTextEntry.DUPLICATE duplicate, boolean active, boolean translationExists, boolean hasNote, boolean isNBSP) Choose segment's attributes based on rules.returns the setting for display the modification information or not Either DISPLAY_MODIFICATION_INFO_NONE, DISPLAY_MODIFICATION_INFO_SELECTED, DISPLAY_MODIFICATION_INFO_ALLReturns font attributes for the modification info line.Returns font attributes for other languages translation.Returns font attributes for paragraph startReturns font attributes for the segment marker.booleanneed to check spell or notbooleandisplay the segment sources or notbooleanbooleanbooleanbooleanbooleanmark Bidirectional control charactersbooleanbooleanbooleanmark non-breakable spaces?booleanbooleanbooleanbooleanbooleanbooleanmark whitespace?booleanvoidsetAutoSpellChecking(boolean autoSpellChecking) voidsetDisplayModificationInfo(String displayModificationInfo) Sets the setting for display the modification information or notvoidsetDisplaySegmentSources(boolean displaySegmentSources) voidsetDoFontFallback(boolean doFontFalback) voidsetMarkAltTranslations(boolean markAltTranslations) voidsetMarkAutoPopulated(boolean val) voidsetMarkBidi(boolean markBidi) voidsetMarkGlossaryMatches(boolean markGlossaryMatches) voidsetMarkLanguageChecker(boolean markLanguageChecker) voidsetMarkNBSP(boolean markNBSP) voidsetMarkNonUniqueSegments(boolean markNonUniqueSegments) voidsetMarkNotedSegments(boolean markNotedSegments) voidsetMarkParagraphDelimitations(boolean delimitations) voidsetMarkTranslated(boolean markTranslated) voidsetMarkUntranslated(boolean markUntranslated) voidsetMarkWhitespace(boolean markWhitespace) voidsetUseTabForAdvance(boolean useTabForAdvance) voidrepaint segments in editor according to new view tag validation options.voidrepaint segments in editor according to new view options.
-
Field Details
-
DISPLAY_MODIFICATION_INFO_NONE
- See Also:
-
DISPLAY_MODIFICATION_INFO_SELECTED
- See Also:
-
DISPLAY_MODIFICATION_INFO_ALL
- See Also:
-
-
Method Details
-
getAdvancerChar
public char getAdvancerChar() -
isUseTabForAdvance
public boolean isUseTabForAdvance()- Specified by:
isUseTabForAdvancein interfaceIEditorSettings
-
setUseTabForAdvance
public void setUseTabForAdvance(boolean useTabForAdvance) - Specified by:
setUseTabForAdvancein interfaceIEditorSettings
-
isMarkTranslated
public boolean isMarkTranslated()- Specified by:
isMarkTranslatedin interfaceIEditorSettings
-
setMarkTranslated
public void setMarkTranslated(boolean markTranslated) - Specified by:
setMarkTranslatedin interfaceIEditorSettings
-
isMarkUntranslated
public boolean isMarkUntranslated()- Specified by:
isMarkUntranslatedin interfaceIEditorSettings
-
isMarkAutoPopulated
public boolean isMarkAutoPopulated()- Specified by:
isMarkAutoPopulatedin interfaceIEditorSettings
-
setMarkAutoPopulated
public void setMarkAutoPopulated(boolean val) - Specified by:
setMarkAutoPopulatedin interfaceIEditorSettings
-
setMarkUntranslated
public void setMarkUntranslated(boolean markUntranslated) - Specified by:
setMarkUntranslatedin interfaceIEditorSettings
-
isDisplaySegmentSources
public boolean isDisplaySegmentSources()display the segment sources or not- Specified by:
isDisplaySegmentSourcesin interfaceIEditorSettings
-
isMarkNonUniqueSegments
public boolean isMarkNonUniqueSegments()- Specified by:
isMarkNonUniqueSegmentsin interfaceIEditorSettings
-
isHideDuplicateSegments
public boolean isHideDuplicateSegments() -
isMarkNotedSegments
public boolean isMarkNotedSegments()- Specified by:
isMarkNotedSegmentsin interfaceIEditorSettings
-
isMarkNBSP
public boolean isMarkNBSP()mark non-breakable spaces?- Specified by:
isMarkNBSPin interfaceIEditorSettings- Returns:
- true when set, false otherwise
-
isMarkWhitespace
public boolean isMarkWhitespace()mark whitespace?- Specified by:
isMarkWhitespacein interfaceIEditorSettings- Returns:
- true when set, false otherwise
-
isMarkBidi
public boolean isMarkBidi()mark Bidirectional control characters- Specified by:
isMarkBidiin interfaceIEditorSettings- Returns:
- true when set, false otherwise
-
isMarkAltTranslations
public boolean isMarkAltTranslations()- Specified by:
isMarkAltTranslationsin interfaceIEditorSettings
-
isDoFontFallback
public boolean isDoFontFallback()- Specified by:
isDoFontFallbackin interfaceIEditorSettings
-
setDisplaySegmentSources
public void setDisplaySegmentSources(boolean displaySegmentSources) - Specified by:
setDisplaySegmentSourcesin interfaceIEditorSettings
-
setMarkNonUniqueSegments
public void setMarkNonUniqueSegments(boolean markNonUniqueSegments) - Specified by:
setMarkNonUniqueSegmentsin interfaceIEditorSettings
-
setMarkNotedSegments
public void setMarkNotedSegments(boolean markNotedSegments) - Specified by:
setMarkNotedSegmentsin interfaceIEditorSettings
-
setMarkNBSP
public void setMarkNBSP(boolean markNBSP) - Specified by:
setMarkNBSPin interfaceIEditorSettings
-
setMarkWhitespace
public void setMarkWhitespace(boolean markWhitespace) - Specified by:
setMarkWhitespacein interfaceIEditorSettings
-
setMarkParagraphDelimitations
public void setMarkParagraphDelimitations(boolean delimitations) - Specified by:
setMarkParagraphDelimitationsin interfaceIEditorSettings
-
isMarkParagraphDelimitations
public boolean isMarkParagraphDelimitations()- Specified by:
isMarkParagraphDelimitationsin interfaceIEditorSettings
-
setMarkBidi
public void setMarkBidi(boolean markBidi) - Specified by:
setMarkBidiin interfaceIEditorSettings
-
setMarkAltTranslations
public void setMarkAltTranslations(boolean markAltTranslations) - Specified by:
setMarkAltTranslationsin interfaceIEditorSettings
-
setDoFontFallback
public void setDoFontFallback(boolean doFontFalback) - Specified by:
setDoFontFallbackin interfaceIEditorSettings
-
isMarkGlossaryMatches
public boolean isMarkGlossaryMatches()- Specified by:
isMarkGlossaryMatchesin interfaceIEditorSettings
-
setMarkGlossaryMatches
public void setMarkGlossaryMatches(boolean markGlossaryMatches) - Specified by:
setMarkGlossaryMatchesin interfaceIEditorSettings
-
isMarkLanguageChecker
public boolean isMarkLanguageChecker()- Specified by:
isMarkLanguageCheckerin interfaceIEditorSettings
-
setMarkLanguageChecker
public void setMarkLanguageChecker(boolean markLanguageChecker) - Specified by:
setMarkLanguageCheckerin interfaceIEditorSettings
-
getDisplayModificationInfo
returns the setting for display the modification information or not Either DISPLAY_MODIFICATION_INFO_NONE, DISPLAY_MODIFICATION_INFO_SELECTED, DISPLAY_MODIFICATION_INFO_ALL- Specified by:
getDisplayModificationInfoin interfaceIEditorSettings
-
setDisplayModificationInfo
Sets the setting for display the modification information or not- Specified by:
setDisplayModificationInfoin interfaceIEditorSettings- Parameters:
displayModificationInfo- Either DISPLAY_MODIFICATION_INFO_NONE , DISPLAY_MODIFICATION_INFO_SELECTED , DISPLAY_MODIFICATION_INFO_ALL
-
isAutoSpellChecking
public boolean isAutoSpellChecking()need to check spell or not- Specified by:
isAutoSpellCheckingin interfaceIEditorSettings
-
setAutoSpellChecking
public void setAutoSpellChecking(boolean autoSpellChecking) - Specified by:
setAutoSpellCheckingin interfaceIEditorSettings
-
updateViewPreferences
public void updateViewPreferences()repaint segments in editor according to new view options. Use when options change to make them effective immediately.- Specified by:
updateViewPreferencesin interfaceIEditorSettings
-
updateTagValidationPreferences
public void updateTagValidationPreferences()repaint segments in editor according to new view tag validation options. Use when options change to make them effective immediately.- Specified by:
updateTagValidationPreferencesin interfaceIEditorSettings
-
getAttributeSet
public AttributeSet getAttributeSet(boolean isSource, boolean isPlaceholder, boolean isRemoveText, SourceTextEntry.DUPLICATE duplicate, boolean active, boolean translationExists, boolean hasNote, boolean isNBSP) Choose segment's attributes based on rules.- Parameters:
isSource- is it a source segment or a target segmentisPlaceholder- is it for a placeholder (OmegaT tag or sprintf-variable etc.) or regular text inside the segment?isRemoveText- is it text that should be removed from translation?duplicate- is the sourceTextEntry a duplicate or not? values: DUPLICATE.NONE, DUPLICATE.FIRST or DUPLICATE.NEXT. See sourceTextEntryste.getDuplicate()active- is it an active segment?translationExists- does a translation already existisNBSP- is the text a non-breakable space- Returns:
- proper AttributeSet to use on displaying the segment.
-
getParagraphStartAttributeSet
Returns font attributes for paragraph start- Returns:
-
getModificationInfoAttributeSet
Returns font attributes for the modification info line.- Returns:
-
getSegmentMarkerAttributeSet
Returns font attributes for the segment marker.- Returns:
-
getOtherLanguageTranslationAttributeSet
Returns font attributes for other languages translation.- Returns:
-