當前位置: 首頁>>代碼示例>>Java>>正文


Java TitledPane.getText方法代碼示例

本文整理匯總了Java中javafx.scene.control.TitledPane.getText方法的典型用法代碼示例。如果您正苦於以下問題:Java TitledPane.getText方法的具體用法?Java TitledPane.getText怎麽用?Java TitledPane.getText使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在javafx.scene.control.TitledPane的用法示例。


在下文中一共展示了TitledPane.getText方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: bind

import javafx.scene.control.TitledPane; //導入方法依賴的package包/類
public void bind(final Accordion accordion, final String propertyName) {
    Object selectedPane = props.getProperty(propertyName);
    for (TitledPane tp : accordion.getPanes()) {
        if (tp.getText() != null && tp.getText().equals(selectedPane)) {
            accordion.setExpandedPane(tp);
            break;
        }
    }
    accordion.expandedPaneProperty().addListener(new ChangeListener<TitledPane>() {

        @Override
        public void changed(ObservableValue<? extends TitledPane> ov, TitledPane t, TitledPane expandedPane) {
            if (expandedPane != null) {
                props.setProperty(propertyName, expandedPane.getText());
            }
        }
    });
}
 
開發者ID:comtel2000,項目名稱:mokka7,代碼行數:19,代碼來源:SessionManager.java

示例2: drawNode

import javafx.scene.control.TitledPane; //導入方法依賴的package包/類
@Override
public Node drawNode() {
    String title = "TitledPane";
    Label content = new Label("Content");
    TitledPane titledPane = new TitledPane(title, content);
    if (titledPane.getText() != title) {
        reportGetterFailure("getTitle()");
    }
    if (titledPane.getContent() != content) {
        reportGetterFailure("getTitle()");
    }
    titledPane.setMinSize(SLOT_WIDTH, SLOT_HEIGHT);
    titledPane.setMaxSize(SLOT_WIDTH, SLOT_HEIGHT);
    titledPane.setPrefSize(SLOT_WIDTH, SLOT_HEIGHT);
    titledPane.setStyle("-fx-border-color: darkgray;");
    return titledPane;
}
 
開發者ID:teamfx,項目名稱:openjfx-8u-dev-tests,代碼行數:18,代碼來源:TitledPaneApp.java

示例3: onActionIncreaseProjectCounter

import javafx.scene.control.TitledPane; //導入方法依賴的package包/類
private void onActionIncreaseProjectCounter(TitledPane titledPane, String projectName) {
    LoggerFacade.INSTANCE.debug(this.getClass(), "On action increase Project counter"); // NOI18N
    
    final String title = titledPane.getText();
    final String counted = title.substring(1, title.indexOf(')')); // NOI18N
    final int counter = Integer.parseInt(counted) + 1;
    titledPane.setText("(" + counter + ") " + projectName); // NOI18N
    
    LoggerFacade.INSTANCE.trace(this.getClass(), "TODO update database with the new counter"); // NOI18N
    
    this.onActionEnsureTitledPaneIsVisible(titledPane);
}
 
開發者ID:Naoghuman,項目名稱:Incubator,代碼行數:13,代碼來源:DailySectionContentPresenter.java

示例4: bind

import javafx.scene.control.TitledPane; //導入方法依賴的package包/類
public void bind(final Accordion accordion, final String propertyName) {
  Object selectedPane = props.getProperty(propertyName);
  for (TitledPane tp : accordion.getPanes()) {
    if (tp.getText() != null && tp.getText().equals(selectedPane)) {
      accordion.setExpandedPane(tp);
      break;
    }
  }
  accordion.expandedPaneProperty().addListener((ov, t, expandedPane) -> {
    if (expandedPane != null) {
      props.setProperty(propertyName, expandedPane.getText());
    }
  });
}
 
開發者ID:comtel2000,項目名稱:jfxvnc,代碼行數:15,代碼來源:SessionContext.java

示例5: getTitledPaneText

import javafx.scene.control.TitledPane; //導入方法依賴的package包/類
protected String getTitledPaneText(TitledPane titledPane) {
    return titledPane.getText();
}
 
開發者ID:jalian-systems,項目名稱:marathonv5,代碼行數:4,代碼來源:JavaFXElementPropertyAccessor.java


注:本文中的javafx.scene.control.TitledPane.getText方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。