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


Java Borders类代码示例

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


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

示例1: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    JPanel buttons = ButtonBarFactory.buildRightAlignedBar(startButton, stopButton);

    FormLayout layout = new FormLayout("right:d, 6dlu, max(d;30dlu):grow");
    DefaultFormBuilder builder = new DefaultFormBuilder(layout, this);
    builder.append("Service status", statusTextField);
    builder.append("", buttons);
    builder.appendParagraphGapRow();
    builder.nextRow();
    builder.append("Started on", startedTextField);
    builder.append("Memory used", memoryTextField);
    builder.append("Error message", errorTextField);
    builder.append("Server address", urlButton);

    setBorder(Borders.DIALOG_BORDER);
}
 
开发者ID:sindremehus,项目名称:subsonic,代码行数:17,代码来源:StatusPanel.java

示例2: createPainterPropertiesPanel

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
/**
     * @param painterControlPanel
     * @return
     */
    private JXPanel createPainterPropertiesPanel() {
        basePainterControlPanel = createBasePainterControlPanel();
        layoutPainterControlPanel = createLayoutPainterControl();
        areaPainterControlPanel = createAreaPainterControlPanel();
        JXPanel properties = new JXPanel();
        FormLayout formLayout = new FormLayout(
                " f:d:n, l:4dlu:n, f:d:n, l:4dlu:n, f:d:n ", // columns
                "t:d:n " 
        ); // rows
        
        PanelBuilder builder = new PanelBuilder(formLayout, properties);
        builder.setBorder(Borders.DLU4_BORDER);
        CellConstraints cl = new CellConstraints();
//        CellConstraints cc = new CellConstraints();
        int currentColumn = 1;
        builder.add(basePainterControlPanel, cl.xy(currentColumn, 1));
        currentColumn +=2;
        builder.add(layoutPainterControlPanel, cl.xy(currentColumn, 1));
        currentColumn +=2;
        builder.add(areaPainterControlPanel, cl.xy(currentColumn, 1));
        currentColumn +=2;
        return properties;
    }
 
开发者ID:RockManJoe64,项目名称:swingx,代码行数:28,代码来源:PainterDemo.java

示例3: createMonthViewDemo

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void createMonthViewDemo() {
    monthView = new JXMonthView();
    monthView.setName("monthView");
    
    // add to container which doesn't grow the size beyond the pref
    JComponent monthViewContainer = new JXPanel();
    monthViewContainer.add(monthView);
    
    JPanel monthViewControlPanel = new JXPanel();
    add(monthViewControlPanel, BorderLayout.SOUTH);

    FormLayout formLayout = new FormLayout(
            "f:m:g, l:4dlu:n, f:m:g", // columns
            "c:d:g, t:2dlu:n, t:d:n "
    ); // rows
    PanelBuilder builder = new PanelBuilder(formLayout, this);
    builder.setBorder(Borders.DLU4_BORDER);
    CellConstraints cc = new CellConstraints();
    
    builder.add(monthViewContainer, cc.xywh(1, 1, 3, 1));
    
    builder.add(createBoxPropertiesPanel(), cc.xywh(1, 3, 1, 1));
    builder.add(createConfigPanel(), cc.xywh(3, 3, 1, 1));
}
 
开发者ID:RockManJoe64,项目名称:swingx,代码行数:25,代码来源:MonthViewDemo.java

示例4: UnifiedToolBar

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
/**
 * Creates a {@code UnifiedToolBar}.
 * 	 
 * @param forceSameWidth
 *            whether the two ends should have the same width to keep the center balanced.
 */
public UnifiedToolBar(boolean forceSameWidth) {
	
	fUnifiedToolBar = new TriAreaComponent(4, forceSameWidth);
	
	// TODO remove below call when Apple fixes bug in Java that doesn't
	// correctly paint the
	// TODO textured window.
	fixUnifiedToolBarOnMacIfNeccessary(fUnifiedToolBar);
	fUnifiedToolBar.getComponent().setBorder(
			Borders.createEmptyBorder("3dlu, 4dlu, 3dlu, 4dlu"));
	installUnifiedToolBarBorder(fUnifiedToolBar.getComponent());
	WindowUtils
			.installJComponentRepainterOnWindowFocusChanged(fUnifiedToolBar
					.getComponent());
}
 
开发者ID:mathieulegoc,项目名称:SmartTokens,代码行数:22,代码来源:UnifiedToolBar.java

示例5: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    FormLayout layout = new FormLayout("d, 6dlu, max(d;30dlu):grow");
    DefaultFormBuilder builder = new DefaultFormBuilder(layout);
    builder.append("Port number", portTextField);
    builder.append(httpsPortCheckBox, httpsPortTextField);
    builder.append("Memory init (MB)", memoryInitTextField);
    builder.append("Memory limit (MB)", memoryTextField);
    builder.append("Context path", contextPathComboBox);

    setBorder(Borders.DIALOG_BORDER);

    setLayout(new BorderLayout(12, 12));
    add(builder.getPanel(), BorderLayout.CENTER);
    JPanel buttons = new ButtonBarBuilder()
        .addGlue()
        .addButton(defaultButton)
        .addRelatedGap()
        .addButton(saveButton)
        .addGlue()
        .build();
    add(buttons, BorderLayout.SOUTH);
}
 
开发者ID:FutureSonic,项目名称:FutureSonic-Server,代码行数:23,代码来源:SettingsPanel.java

示例6: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    JPanel buttons = new ButtonBarBuilder()
        .addGlue()
        .addButton(startButton)
        .addRelatedGap()
        .addButton(stopButton)
        .build();
    FormLayout layout = new FormLayout("right:d, 6dlu, max(d;30dlu):grow");
    DefaultFormBuilder builder = new DefaultFormBuilder(layout, this);
    builder.append("Service status", statusTextField);
    builder.append("", buttons);
    builder.appendParagraphGapRow();
    builder.nextRow();
    builder.append("Started on", startedTextField);
    builder.append("Memory used", memoryTextField);
    builder.append("Error message", errorTextField);
    builder.append("Server address", urlButton);

    setBorder(Borders.DIALOG_BORDER);
}
 
开发者ID:FutureSonic,项目名称:FutureSonic-Server,代码行数:21,代码来源:StatusPanel.java

示例7: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
@SuppressWarnings("deprecation")
private void layoutComponents() {
       FormLayout layout = new FormLayout("d, 6dlu, max(d;30dlu):grow");
       DefaultFormBuilder builder = new DefaultFormBuilder(layout);
       builder.append("Port number", portTextField);
       builder.append(httpsPortCheckBox, httpsPortTextField);
       builder.append("Memory init (MB)", memoryInitTextField);
       builder.append("Memory limit (MB)", memoryTextField);
       builder.append("Context path", contextPathComboBox);

       setBorder(Borders.DIALOG_BORDER);

       setLayout(new BorderLayout(12, 12));
       add(builder.getPanel(), BorderLayout.CENTER);
       JPanel buttons = new ButtonBarBuilder()
           .addGlue()
           .addButton(defaultButton)
           .addRelatedGap()
           .addButton(saveButton)
           .addGlue()
           .build();
       add(buttons, BorderLayout.SOUTH);
   }
 
开发者ID:MadMarty,项目名称:madsonic-server-5.1,代码行数:24,代码来源:SettingsPanel.java

示例8: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
@SuppressWarnings("deprecation")
private void layoutComponents() {
       tabbedPane.add("Status", statusPanel);
       tabbedPane.add("Settings", settingsPanel);

       JPanel pane = (JPanel) getContentPane();
       pane.setLayout(new BorderLayout(10, 10));
       pane.add(tabbedPane, BorderLayout.CENTER);
       JPanel buttons = new ButtonBarBuilder()
           .addGlue()
           .addButton(closeButton)
           .build();
       pane.add(buttons, BorderLayout.SOUTH);

       pane.setBorder(Borders.TABBED_DIALOG_BORDER);
   }
 
开发者ID:MadMarty,项目名称:madsonic-server-5.1,代码行数:17,代码来源:MadsonicFrame.java

示例9: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    FormLayout layout = new FormLayout("d, 6dlu, max(d;30dlu):grow");
    DefaultFormBuilder builder = new DefaultFormBuilder(layout);
    builder.append("Port number", portTextField);
    builder.append(httpsPortCheckBox, httpsPortTextField);
    builder.append("Memory limit (MB)", memoryTextField);
    builder.append("Context path", contextPathComboBox);

    setBorder(Borders.DIALOG_BORDER);

    setLayout(new BorderLayout(12, 12));
    add(builder.getPanel(), BorderLayout.CENTER);
    add(ButtonBarFactory.buildCenteredBar(defaultButton, saveButton), BorderLayout.SOUTH);
}
 
开发者ID:sindremehus,项目名称:subsonic,代码行数:15,代码来源:SettingsPanel.java

示例10: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    tabbedPane.add("Status", statusPanel);
    tabbedPane.add("Settings", settingsPanel);

    JPanel pane = (JPanel) getContentPane();
    pane.setLayout(new BorderLayout(10, 10));
    pane.add(tabbedPane, BorderLayout.CENTER);
    pane.add(ButtonBarFactory.buildCloseBar(closeButton), BorderLayout.SOUTH);

    pane.setBorder(Borders.TABBED_DIALOG_BORDER);
}
 
开发者ID:sindremehus,项目名称:subsonic,代码行数:12,代码来源:SubsonicFrame.java

示例11: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    JPanel pane = (JPanel) getContentPane();
    pane.setLayout(new BorderLayout(10, 10));
    pane.add(statusPanel, BorderLayout.CENTER);
    pane.add(ButtonBarFactory.buildRightAlignedBar(hideButton, exitButton), BorderLayout.SOUTH);

    pane.setBorder(Borders.DIALOG_BORDER);
}
 
开发者ID:sindremehus,项目名称:subsonic,代码行数:9,代码来源:SubsonicFrame.java

示例12: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    FormLayout layout = new FormLayout("right:d, 6dlu, max(d;30dlu):grow");
    DefaultFormBuilder builder = new DefaultFormBuilder(layout, this);
    builder.append("Started on", startedTextField);
    builder.append("Memory used", memoryTextField);
    builder.append("Error message", errorTextField);
    builder.append("Server address", urlButton);

    setBorder(Borders.DIALOG_BORDER);
}
 
开发者ID:sindremehus,项目名称:subsonic,代码行数:11,代码来源:StatusPanel.java

示例13: initComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void initComponents() {
        list = new JXList();
        list.setName("list");

        JPanel monthViewContainer = new JXPanel();
        FormLayout formLayout = new FormLayout(
                "5dlu, f:d:g ", // l:4dlu:n, f:d:g", // columns
                "c:d:n " +
                ", t:4dlu:n, f:d:g " +
                ", t:4dlu:n, c:d:n" +
                ", t:4dlu:n, c:d:n" +
                ", t:4dlu:n, c:d:n"
        ); // rows
        PanelBuilder builder = new PanelBuilder(formLayout, monthViewContainer);
        builder.setBorder(Borders.DLU4_BORDER);
//        CellConstraints cl = new CellConstraints();
        CellConstraints cc = new CellConstraints();
        
        JXTitledSeparator areaSeparator = new JXTitledSeparator();
        areaSeparator.setName("listSeparator");
        builder.add(areaSeparator, cc.xywh(1, 1, 2, 1));
        builder.add(new JScrollPane(list), cc.xywh(2, 3, 1, 1));
        
        
        add(monthViewContainer, BorderLayout.CENTER);
        
        JComponent extended = createExtendedConfigPanel();
        add(extended, BorderLayout.EAST);
    }
 
开发者ID:RockManJoe64,项目名称:swingx,代码行数:30,代码来源:XListDemo.java

示例14: buildControl

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private JComponent buildControl() {
    // COLUMN SPECS:
    // r:p:n, l:4dluX:n, f:max(p;100dluX):n, l:4dluX:n, f:max(p;50dluX):n
    // ROW SPECS:
    // c:d:n, t:4dluY:n, c:d:n
    //
    // COLUMN GROUPS: {}
    // ROW GROUPS: {}
    //
    // COMPONENT CONSTRAINTS
    // ( 1, 1, 1, 1, "d=r, d=c"); javax.swing.JLabel "Modus"; name=modus
    // ( 3, 1, 3, 1, "d=f, d=c"); javax.swing.JPanel; name=moduscontrol
    // ( 1, 3, 1, 1, "d=r, d=c"); javax.swing.JLabel "Input"; name=input
    // ( 3, 3, 1, 1, "d=f, d=c"); javax.swing.JTextField; name=searchText
    // ( 5, 3, 1, 1, "d=f, d=c"); de.kleopatra.view.JButton; name=next
    //

    FormLayout formLayout = new FormLayout(
            "r:p:n, l:4dlu:n, f:max(p;100dlu):n, l:4dlu:n, f:max(p;50dlu):n", // columns
            "c:d:n, t:4dlu:n, c:d:n, t:4dlu:n, c:d:n"); // rows
    JXPanel control = new JXPanel();
    PanelBuilder builder = new PanelBuilder(formLayout, control);
    builder.setBorder(Borders.BUTTON_BAR_GAP_BORDER);
    CellConstraints cl = new CellConstraints();
    CellConstraints cc = new CellConstraints();
    radioGroupLabel = builder.addLabel("", cl.xywh(1, 1, 1, 1), radioGroup, cc.xywh(3,
            1, 3, 1));
    inputTextLabel = builder.addLabel("", cl.xywh(1, 3, 1, 1), inputText, cc
            .xywh(3, 3, 1, 1));
    patternLabel = builder.addLabel("", cl.xywh(1, 5, 1, 1), patternText, cc.xywh(
            3, 5, 1, 1));
    builder.add(nextButton, cc.xywh(5, 3, 1, 1));
    return control;
}
 
开发者ID:RockManJoe64,项目名称:swingx,代码行数:35,代码来源:DecoratorDemo.java

示例15: layoutComponents

import com.jgoodies.forms.factories.Borders; //导入依赖的package包/类
private void layoutComponents() {
    tabbedPane.add("Status", statusPanel);
    tabbedPane.add("Settings", settingsPanel);

    JPanel pane = (JPanel) getContentPane();
    pane.setLayout(new BorderLayout(10, 10));
    pane.add(tabbedPane, BorderLayout.CENTER);
    JPanel buttons = new ButtonBarBuilder()
        .addGlue()
        .addButton(closeButton)
        .build();
    pane.add(buttons, BorderLayout.SOUTH);

    pane.setBorder(Borders.TABBED_DIALOG_BORDER);
}
 
开发者ID:FutureSonic,项目名称:FutureSonic-Server,代码行数:16,代码来源:SubsonicFrame.java


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