当前位置: 首页>>代码示例>>Java>>正文


Java FontFieldEditor类代码示例

本文整理汇总了Java中org.eclipse.jface.preference.FontFieldEditor的典型用法代码示例。如果您正苦于以下问题:Java FontFieldEditor类的具体用法?Java FontFieldEditor怎么用?Java FontFieldEditor使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


FontFieldEditor类属于org.eclipse.jface.preference包,在下文中一共展示了FontFieldEditor类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createFontSettings

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
private void createFontSettings(Composite composite) {
	Composite panel = new Composite(composite, SWT.NULL);
	GridLayout layout = new GridLayout();
	layout.marginWidth = 0;
	layout.marginHeight = 0;
	layout.numColumns = 4;
	panel.setLayout(layout);
	GridData data = new GridData();
	data.horizontalSpan = 2;
       data.grabExcessHorizontalSpace = true;
       data.horizontalAlignment = SWT.CENTER;
	panel.setLayoutData(data);

	fontTypeEditor = new FontFieldEditor(ILogViewerConstants.PREF_EDITOR_FONT_STYLE,LogViewerPlugin.getResourceString("preferences.contenteditor.font.style.text"),panel); //$NON-NLS-1$
	fontTypeEditor.setChangeButtonText(LogViewerPlugin.getResourceString("preferences.contenteditor.fontl.style.button.text")); //$NON-NLS-1$
	fontTypeEditor.setPreferenceStore(doGetPreferenceStore());
	fontTypeEditor.fillIntoGrid(panel, 3);
	fontTypeEditor.setPage(this);
	fontTypeEditor.load();
}
 
开发者ID:anb0s,项目名称:LogViewer,代码行数:21,代码来源:LogViewerPreferences.java

示例2: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors() {
	addField(new BooleanFieldEditor(PreferenceKeys.RESULTS_FADE_AWAY_MODE,
			local.getString("resFedAw"), getFieldEditorParent()));

	addField(new ComboFieldEditor(PreferenceKeys.RESULTS_ANIMATION_DELAY,
			local.getString("resAnDel"), RESULTS_ANIMATION_DELAY_OPTIONS,
			getFieldEditorParent()));

	addField(new ComboFieldEditor(PreferenceKeys.RESULTS_WIDTH_PERCENTAGE,
			local.getString("resPreSz"), RESULTS_PERCENTAGE,
			getFieldEditorParent()));

	addField(new ColorFieldEditor(PreferenceKeys.RESULTS_COLOR,
			local.getString("resCol"), getFieldEditorParent()));
	addField(new FontFieldEditor(PreferenceKeys.RESULTS_FONT,
			local.getString("resFnt"), getFieldEditorParent()));
}
 
开发者ID:evilwan,项目名称:raptor-chess-interface,代码行数:19,代码来源:ChessBoardResultsPage.java

示例3: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
/**
 * Creates the field editors. Field editors are abstractions of the common
 * GUI blocks needed to manipulate various types of preferences. Each field
 * editor knows how to save and restore itself.
 */
@Override
public void createFieldEditors()
{
	addField(new FontFieldEditor(
			EventPreferences.CMDLINE_FONT, "Schrift:", getFieldEditorParent()) );
	addField(new IntegerFieldEditor(
			EventPreferences.CMDLINE_INDENT_WIDTH, "Einrückungstiefe", getFieldEditorParent()) );
	addField(new ColorListEditor(new String[][]
	{
			{EventPreferences.CMDLINE_BACKGROUND_COLOR, 	"Hintergrund Farbe"},
			{EventPreferences.CMDLINE_COLOR_DEFAULT, 		"Default Farbe"},
			{EventPreferences.CMDLINE_COLOR_COMMENT, 		"Kommentare"},
			{EventPreferences.CMDLINE_COLOR_CONTROL, 		"Kontrollstrukturen"},
			{EventPreferences.CMDLINE_COLOR_ASSIGNMENT, 	"Zuweisungen"},
			{EventPreferences.CMDLINE_COLOR_FUNCTION, 		"Funktionen"},
	}, "Farb-Schema:", getFieldEditorParent()) );
}
 
开发者ID:TheWhiteShadow3,项目名称:cuina,代码行数:23,代码来源:EventPreferencePage.java

示例4: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors() {
	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_OBSERVING_OPEN_PARTNER_BOARD,
			local.getString("bugPageVar1"),
			getFieldEditorParent()));

	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_PLAYING_OPEN_PARTNER_BOARD,
			local.getString("bugPageVar2"),
			getFieldEditorParent()));
	
	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_SHOW_BUGWHO_ON_PARTNERSHIP,
			local.getString("bugPageVar3"),
			getFieldEditorParent()));

	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_IS_PLAYING_PARTNERSHIP_OFFERED_SOUND,
			local.getString("bugPageVar4"),
			getFieldEditorParent()));

	addField(new BooleanFieldEditor(
			PreferenceKeys.BOARD_SHOW_BUGHOUSE_SIDE_UP_TIME,
			local.getString("bugPageVar5"), getFieldEditorParent()));

	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_SPEAK_COUNTDOWN_ON_PARTNER_BOARD,
			local.getString("bugPageVar6"), getFieldEditorParent()));

	addField(new BooleanFieldEditor(
			PreferenceKeys.BUGHOUSE_SPEAK_PARTNER_TELLS,
			local.getString("bugPageVar7"), getFieldEditorParent()));

	addField(new FontFieldEditor(PreferenceKeys.BUG_BUTTONS_FONT,
			local.getString("bugPageVar8"), getFieldEditorParent()));
}
 
开发者ID:evilwan,项目名称:raptor-chess-interface,代码行数:38,代码来源:BughousePage.java

示例5: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors() {

	String[][] sliderWidthPreferences = { { local.getString("tiny"), "3" },
			{ local.getString("small"), "5" }, { local.getString("medium"), "8" }, { local.getString("large"), "11" },
			{ local.getString("extWide"), "15" } };
	ComboFieldEditor setFieldEditor = new ComboFieldEditor(
			PreferenceKeys.APP_SASH_WIDTH, local.getString("divSashWid"),
			sliderWidthPreferences, getFieldEditorParent());
	addField(setFieldEditor);

	ColorFieldEditor pingTimeColor = new ColorFieldEditor(
			PreferenceKeys.APP_PING_COLOR, local.getString("pingTFontCol"),
			getFieldEditorParent());
	addField(pingTimeColor);

	addField(pingTimeColor);
	FontFieldEditor pingTimeFont = new FontFieldEditor(
			PreferenceKeys.APP_PING_FONT, local.getString("pingTFont"),
			getFieldEditorParent());
	addField(pingTimeFont);

	ColorFieldEditor statusBarFontColor = new ColorFieldEditor(
			PreferenceKeys.APP_STATUS_BAR_COLOR, local.getString("statBarFontCol"),
			getFieldEditorParent());
	addField(statusBarFontColor);

	FontFieldEditor statusBarFont = new FontFieldEditor(
			PreferenceKeys.APP_STATUS_BAR_FONT, local.getString("statBarFont"),
			getFieldEditorParent());
	addField(statusBarFont);
	
	addField(new BooleanFieldEditor(
			PreferenceKeys.APP_SHOW_STATUS_BAR,
			local.getString("showWinStar"),
			getFieldEditorParent()));

}
 
开发者ID:evilwan,项目名称:raptor-chess-interface,代码行数:39,代码来源:RaptorWindowPage.java

示例6: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors()
{
	// TODO Auto-generated method stub
	m_colorSelectors = new FontFieldEditor[FontKey.values().length];
	Composite parent = getFieldEditorParent();
	for (FontKey key : FontKey.values())
	{
		FontFieldEditor selector = new FontFieldEditor(key.getPreferenceName(), key.description, TEST_TEXT, parent);
		m_colorSelectors[key.ordinal()] = selector;
		addField(selector);
	}
}
 
开发者ID:Spacecraft-Code,项目名称:SPELL,代码行数:14,代码来源:FontsPreferencePage.java

示例7: performApply

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
public void performApply()
{
	for (FontKey key : FontKey.values())
	{
		FontFieldEditor selector = m_colorSelectors[key.ordinal()];
		Font font = selector.getPreviewControl().getFont();
		m_conf.setFont(key, font);
	}
}
 
开发者ID:Spacecraft-Code,项目名称:SPELL,代码行数:11,代码来源:FontsPreferencePage.java

示例8: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
/**
 *
 */
public void createFieldEditors() {
	addField(new ComboFieldEditor(
			P_ELEMENT_DESIGN_BORDER_STYLE,
			Messages.DesignerPreferencePage_element_design_border_style,
			new String[][] {
					{ Messages.DesignerPreferencePage_corners, "corners" }, { Messages.common_rectangle, "rectangle" } }, getFieldEditorParent())); //$NON-NLS-1$ //$NON-NLS-2$
	addField(new ColorFieldEditor(P_ELEMENT_DESIGN_BORDER_COLOR, Messages.DesignerPreferencePage_elementbordercolor,
			getFieldEditorParent()));

	addField(new ComboFieldEditor(P_PAGE_DESIGN_BORDER_STYLE, Messages.DesignerPreferencePage_page_border_style,
			new String[][] { { Messages.DesignerPreferencePage_fancy_shadow, DEFAULT_BORDERSTYLE },
					{ Messages.DesignerPreferencePage_simple_shadow, "rectangle" } }, getFieldEditorParent())); //$NON-NLS-1$ //$NON-NLS-2$

	addField(new ComboFieldEditor(P_PAGE_DEFAULT_UNITS, Messages.DesignerPreferencePage_unit, Unit.getUnits2(),
			getFieldEditorParent()));

	addField(new BooleanFieldEditor(P_SHOW_REPORT_BAND_NAMES, Messages.DesignerPreferencePage_show_band_names,
			getFieldEditorParent()));
	addField(new ColorFieldEditor(P_CONTAINER_MARGIN_COLOR, Messages.DesignerPreferencePage_common_bandmargincolor,
			getFieldEditorParent()));
	addField(new ColorFieldEditor(P_PAGE_MARGIN_COLOR, Messages.DesignerPreferencePage_pageprintmargincolor,
			getFieldEditorParent()));
	addField(new ColorFieldEditor(P_PAGE_BACKGROUND, Messages.DesignerPreferencePage_pagebackground,
			getFieldEditorParent()));
	addField(new FontFieldEditor(P_INTERNAL_EDITORS_FONT, Messages.DesignerPreferencePage_InternalEditorsFont,
			getFieldEditorParent()));

	addField(new ComboFieldEditor(BEHAVIOR_ON_FIELD_DROP, Messages.DesignerPreferencePage_field_behavior,
			new String[][] { { Messages.DesignerPreferencePage_field_behavior_label, BEHAVIOR_CREATE_LABEL },
					{ Messages.DesignerPreferencePage_field_behavior_nothing, BEHAVIOR_DO_NOTHING },
					{ Messages.DesignerPreferencePage_field_behavior_ask, BEHAVIOR_ASK_EVERYTIME } }, getFieldEditorParent()));
	addField(new BooleanFieldEditor(P_USE_FIELD_DESCRIPTION, Messages.DesignerPreferencePage_UseDescriptionForLabelText,
			getFieldEditorParent()));
	addField(new BooleanFieldEditor(P_SAVE_ON_PREVIEW, Messages.DesignerPreferencePage_savereportonpreview, getFieldEditorParent()));
	addField(new BooleanFieldEditor(P_CENTER_SELECTION, Messages.DesignerPreferencePage_centerEditorOption, getFieldEditorParent()));
	addField(new BooleanFieldEditor(P_RESIZE_CONTAINER, Messages.DesignerPreferencePage_autoresizeBand, getFieldEditorParent()));
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:41,代码来源:DesignerPreferencePage.java

示例9: createUI_12_Gallery

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
private void createUI_12_Gallery(final Composite parent) {

		final Group group = new Group(parent, SWT.NONE);
		GridDataFactory.fillDefaults().grab(true, false).applyTo(group);
		GridLayoutFactory.swtDefaults().applyTo(group);
		group.setText(Messages.PrefPage_Photo_Viewer_Group_PhotoGallery);
		{
			/*
			 * text min size
			 */
			createUI_14_MinSize(group);

			/*
			 * gallery font
			 */
			_galleryFontEditor = new FontFieldEditor(IPhotoPreferences.PHOTO_VIEWER_FONT, //
					Messages.PrefPage_Photo_Viewer_Label_FontEditor,
					Messages.PrefPage_Photo_Viewer_Label_FontExample,
					group);
			_galleryFontEditor.setPreferenceStore(_prefStore);
			_galleryFontEditor.setPage(this);
			_galleryFontEditor.load();
			_galleryFontEditor.setPropertyChangeListener(this);
		}

		// force 2 columns
		final GridLayout gl = (GridLayout) group.getLayout();
		gl.numColumns = 2;
		gl.marginWidth = 5;
		gl.marginHeight = 5;
		gl.makeColumnsEqualWidth = true;
	}
 
开发者ID:wolfgang-ch,项目名称:mytourbook,代码行数:33,代码来源:PrefPagePhotoDirectory.java

示例10: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
/**
 * Creates the field editors. Field editors are abstractions of
 * the common GUI blocks needed to manipulate various types
 * of preferences. Each field editor knows how to save and
 * restore itself.
 */
@Override
public void createFieldEditors() {
	Composite parent = getFieldEditorParent();

	addField(new LabelFieldEditor  ("General", parent, true));
	addField(new BooleanFieldEditor(PrefCst.P_STARTUP_CHECK, 		"Check resources derived state at startup", parent));
	addField(new BooleanFieldEditor(PrefCst.P_ENABLE_MARKER, 		"Add markers in .derived file (per-rule info or warn)", parent));

	addField(new LabelFieldEditor  ("Trace", parent, true));
	addField(new BooleanFieldEditor(PrefCst.P_OUTPUT_LOG, 			"Output in the .log file (in workspace/.metadata/)", parent));
	addField(new BooleanFieldEditor(PrefCst.P_OUTPUT_STD, 			"Output in the standard output streams (console)", parent));
	addField(new BooleanFieldEditor(PrefCst.P_TRACE_WARN, 			"Trace warnings (recommended)", parent));
	addField(new BooleanFieldEditor(PrefCst.P_TRACE_INFO, 			"Trace info", parent));
	addField(new BooleanFieldEditor(PrefCst.P_TRACE_DEBUG, 			"Trace debug", parent));

	addField(new LabelFieldEditor  ("Decoration - Label", parent, true));
	addField(new LabelFieldEditor  ("NOTE: decorations may be disabled at workspace level,", parent));
	addField(new LabelFieldEditor  ("See General > Appearance > Label Decorations", parent));
	addField(new BooleanFieldEditor(PrefCst.P_DECO_LABEL_TEXT, 		"Affect the label of derived resources", parent));
	addField(new StringFieldEditor (PrefCst.P_DECO_PREFIX, 			"Label prefix", parent));
	addField(new StringFieldEditor (PrefCst.P_DECO_SUFFIX, 			"Label suffix", parent));
	addField(new BooleanFieldEditor(PrefCst.P_DECO_LABEL_FCOLOR, 	"Override foreground color", parent));
	addField(new ColorFieldEditor  (PrefCst.P_DECO_FOREGROUND, 		"Label foreground", parent));
	addField(new BooleanFieldEditor(PrefCst.P_DECO_LABEL_BCOLOR, 	"Override background color", parent));
	addField(new ColorFieldEditor  (PrefCst.P_DECO_BACKGROUND, 		"Label background", parent));
	addField(new BooleanFieldEditor(PrefCst.P_ENABLE_DECO_FONT, 	"Override font", parent));
	addField(new FontFieldEditor   (PrefCst.P_DECO_LABEL_FONT, 		"Derived resources font", parent));

	addField(new LabelFieldEditor("Decoration - Icon", parent, true));
	addField(new ColorFieldEditor  (PrefCst.P_ICON_COLOR, 			"Icon color (hue only)", parent));
	addField(new BooleanFieldEditor(PrefCst.P_ENABLE_CONF_ICON, 	"Replace icon of .derived conf file", parent));
	addField(new BooleanFieldEditor(PrefCst.P_ENABLE_DECO_ICON, 	"Show an icon on derived resources", parent));
	String[][] comboLocation = {
		{"top left", 	"TOP_LEFT"}, 	{"top right", 	"TOP_RIGHT"},
		{"bottom left", "BOTTOM_LEFT"}, {"bottom right","BOTTOM_RIGHT"},
	};
	addField(new RadioGroupFieldEditor( PrefCst.P_DECO_ICON_LOC, "Decoration icon location", 2,comboLocation, parent, true));
}
 
开发者ID:nodj,项目名称:AutoDeriv,代码行数:45,代码来源:MainPreferencePage.java

示例11: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
/**
 * Creates the field editors. Field editors are abstractions of the common
 * GUI blocks needed to manipulate various types of preferences. Each field
 * editor knows how to save and restore itself.
 */
@Override
public void createFieldEditors()
{
	addField(new FontFieldEditor(
			ScriptPreferences.CMDLINE_FONT, "Schrift:", getFieldEditorParent()) );
	addField(new IntegerFieldEditor(
			ScriptPreferences.CMDLINE_INDENT_WIDTH, "Einrückungstiefe", getFieldEditorParent()) );
	addField(new ColorListEditor(new String[][]
	{
			{ScriptPreferences.CMDLINE_BACKGROUND_COLOR, 	"Hintergrund Farbe"},
			{ScriptPreferences.CMDLINE_COLOR_DEFAULT, 		"Default Farbe"},
			{ScriptPreferences.CMDLINE_COLOR_COMMENT, 		"Kommentare"},
			{ScriptPreferences.CMDLINE_COLOR_CONTROL, 		"Kontrollstrukturen"},
			{ScriptPreferences.CMDLINE_COLOR_ASSIGNMENT, 	"Zuweisungen"},
			{ScriptPreferences.CMDLINE_COLOR_FUNCTION, 		"Funktionen"},
	}, "Farb-Schema:", getFieldEditorParent()) );
	
	addField(new ComboFieldEditor(ScriptPreferences.CMDLINE_DEFAULT_NODE, "Standard Dialog", new String[][]
	{
		{ScriptUtil.getTitleForNode(CallNode.class), 	"CallNode"},
		{ScriptUtil.getTitleForNode(AsgNode.class), 	"AsgNode"},
		{ScriptUtil.getTitleForNode(IfNode.class), 		"IfNode"},
		{ScriptUtil.getTitleForNode(WhileNode.class), 	"WhileNode"},
		{ScriptUtil.getTitleForNode(CaseNode.class), 	"CaseNode"},
	}, getFieldEditorParent()));
}
 
开发者ID:TheWhiteShadow3,项目名称:cuina,代码行数:32,代码来源:ScriptPreferencePage.java

示例12: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors() {
	addField(new FontFieldEditor(PreferenceKeys.BOARD_CLOCK_FONT,
			local.getString("chessBFontsP1"), getFieldEditorParent()));

	FontFieldEditor coordinatesFont = new FontFieldEditor(
			PreferenceKeys.BOARD_COORDINATES_FONT, local.getString("chessBFontsP2"),
			getFieldEditorParent());
	addField(coordinatesFont);

	FontFieldEditor gameDescriptionFont = new FontFieldEditor(
			PreferenceKeys.BOARD_GAME_DESCRIPTION_FONT,
			local.getString("chessBFontsP3"), getFieldEditorParent());
	addField(gameDescriptionFont);

	FontFieldEditor lagFont = new FontFieldEditor(
			PreferenceKeys.BOARD_LAG_FONT, local.getString("chessBFontsP4"),
			getFieldEditorParent());
	addField(lagFont);

	FontFieldEditor lastMoveFont = new FontFieldEditor(
			PreferenceKeys.BOARD_STATUS_FONT, local.getString("chessBFontsP5"),
			getFieldEditorParent());
	addField(lastMoveFont);

	FontFieldEditor openingDescriptionFont = new FontFieldEditor(
			PreferenceKeys.BOARD_OPENING_DESC_FONT, local.getString("chessBFontsP6"),
			getFieldEditorParent());
	addField(openingDescriptionFont);

	FontFieldEditor pieceJailFont = new FontFieldEditor(
			PreferenceKeys.BOARD_PIECE_JAIL_FONT,
			local.getString("chessBFontsP7"), getFieldEditorParent());
	addField(pieceJailFont);

	FontFieldEditor playerNameFont = new FontFieldEditor(
			PreferenceKeys.BOARD_PLAYER_NAME_FONT,
			local.getString("chessBFontsP8"), getFieldEditorParent());
	addField(playerNameFont);

	FontFieldEditor premovesFont = new FontFieldEditor(
			PreferenceKeys.BOARD_OPENING_DESC_FONT, local.getString("chessBFontsP9"),
			getFieldEditorParent());
	addField(premovesFont);
}
 
开发者ID:evilwan,项目名称:raptor-chess-interface,代码行数:46,代码来源:ChessBoardFontsPage.java

示例13: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
@Override
protected void createFieldEditors() {
	ComboFieldEditor consoleChars = new ComboFieldEditor(
			PreferenceKeys.CHAT_MAX_CONSOLE_CHARS,
			local.getString("chatConsP1"), CONSOLE_CHARS,
			getFieldEditorParent());
	addField(consoleChars);

	ColorFieldEditor inputTextBackground = new ColorFieldEditor(
			PreferenceKeys.CHAT_INPUT_BACKGROUND_COLOR,
			local.getString("chatConsP2"), getFieldEditorParent());
	addField(inputTextBackground);

	ColorFieldEditor consoleBackground = new ColorFieldEditor(
			PreferenceKeys.CHAT_CONSOLE_BACKGROUND_COLOR,
			local.getString("chatConsP3"), getFieldEditorParent());
	addField(consoleBackground);

	FontFieldEditor inputFont = new FontFieldEditor(
			PreferenceKeys.CHAT_INPUT_FONT, local.getString("chatConsP4"),
			getFieldEditorParent());
	addField(inputFont);

	ColorFieldEditor outputTextBackground = new ColorFieldEditor(
			PreferenceKeys.CHAT_OUTPUT_BACKGROUND_COLOR,
			local.getString("chatConsP5"), getFieldEditorParent());
	addField(outputTextBackground);

	ColorFieldEditor promptColor = new ColorFieldEditor(
			PreferenceKeys.CHAT_PROMPT_COLOR,
			local.getString("chatConsP6"), getFieldEditorParent());
	addField(promptColor);

	ColorFieldEditor outputTextForeground = new ColorFieldEditor(
			PreferenceKeys.CHAT_OUTPUT_TEXT_COLOR,
			local.getString("chatConsP7"), getFieldEditorParent());
	addField(outputTextForeground);

	addField(new FontFieldEditor(
			PreferenceKeys.CHAT_OUTPUT_FONT, local.getString("chatConsP8"),
			getFieldEditorParent()));

	ColorFieldEditor linkTextColor = new ColorFieldEditor(
			PreferenceKeys.CHAT_LINK_UNDERLINE_COLOR, local.getString("chatConsP9"),
			getFieldEditorParent());
	addField(linkTextColor);

	ColorFieldEditor quoteUnderlineColor = new ColorFieldEditor(
			PreferenceKeys.CHAT_QUOTE_UNDERLINE_COLOR,
			local.getString("chatConsP10"), getFieldEditorParent());
	addField(quoteUnderlineColor);

	Label warningLabel = new Label(getFieldEditorParent(), SWT.NONE);
	warningLabel.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true,
			false, 3, 1));
	warningLabel
			.setText(WordUtils
					.wrap(local.getString("chatConsP11"), 70));
}
 
开发者ID:evilwan,项目名称:raptor-chess-interface,代码行数:60,代码来源:ChatConsolePage.java

示例14: createUI

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
private Composite createUI(final Composite parent) {

		final IPreferenceStore prefStore = getPreferenceStore();

		final Composite container = new Composite(parent, SWT.NONE);
		GridDataFactory.fillDefaults().grab(true, false).applyTo(container);
		GridLayoutFactory.fillDefaults().applyTo(container);
		{
			final Composite infoContainer = new Composite(container, SWT.NONE);
			GridDataFactory.fillDefaults().grab(true, false).applyTo(infoContainer);
			GridLayoutFactory.fillDefaults().applyTo(infoContainer);
			{

				// checkbox: show tile info
				_chkShowTileInfo = new BooleanFieldEditor(
						IMappingPreferences.SHOW_MAP_TILE_INFO,
						Messages.pref_map_show_tile_info,
						infoContainer);
				_chkShowTileInfo.setPreferenceStore(prefStore);
				_chkShowTileInfo.setPage(this);
				_chkShowTileInfo.load();
			}

 			final Composite fontContainer = new Composite(container, SWT.NONE);
			GridDataFactory.fillDefaults().indent(0, 20).grab(true, false).applyTo(fontContainer);
			GridLayoutFactory.fillDefaults().applyTo(fontContainer);
			{
				// font: mono space
				_monoFontEditor = new FontFieldEditor(
						IMappingPreferences.THEME_FONT_LOGGING,
						Messages.Theme_Font_Logging,
						Messages.Theme_Font_Logging_PREVIEW_TEXT,
						fontContainer);
				_monoFontEditor.setPreferenceStore(prefStore);
				_monoFontEditor.setPage(this);
				_monoFontEditor.load();
			}
			// force 2 columns
			final GridLayout gl = (GridLayout) fontContainer.getLayout();
			gl.numColumns = 2;
			gl.makeColumnsEqualWidth = true;
		}

		return container;
	}
 
开发者ID:wolfgang-ch,项目名称:mytourbook,代码行数:46,代码来源:PrefPageMap.java

示例15: createFieldEditors

import org.eclipse.jface.preference.FontFieldEditor; //导入依赖的package包/类
protected void createFieldEditors() {
	addField(new FontFieldEditor(CMD_FONT, "&Font:", "ABCabc0123", getFieldEditorParent()));
	addField(new BooleanFieldEditor(CMD_BROWSER_SWING, "Use an alternative output display to try to fix output problems.", getFieldEditorParent()));
}
 
开发者ID:DaveVoorhis,项目名称:Rel,代码行数:5,代码来源:PreferencePageCmd.java


注:本文中的org.eclipse.jface.preference.FontFieldEditor类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。