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


Java TextField.setAlignment方法代码示例

本文整理汇总了Java中javafx.scene.control.TextField.setAlignment方法的典型用法代码示例。如果您正苦于以下问题:Java TextField.setAlignment方法的具体用法?Java TextField.setAlignment怎么用?Java TextField.setAlignment使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在javafx.scene.control.TextField的用法示例。


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

示例1: constructContainer

import javafx.scene.control.TextField; //导入方法依赖的package包/类
@Override
public Parent constructContainer()
{
	bp.setId("loginviewbg");
	
	AllFields = new VBox(50);
	AllFields.setAlignment(Pos.CENTER);
	AllFields.setMaxWidth(300);
	AllFields.setPadding(new Insets(20));
	
	Identifier = new HBox();
	Status = new HBox();
	Bottom = new HBox();
	
	inputName = new TextField();
	inputName.setPromptText("Names der Door");
	inputName.setAlignment(Pos.CENTER_LEFT);
	
	name = new Label("Name:");
	status = new Label("Status:");
	statusValue = new Label("{Door bereits vorhanden}");

	btnCreate = new AppButton("Erstellen");
	back = new BackButton(getFXController(),"Abbrechen");
	
	Identifier.getChildren().addAll(name,inputName);
	Status.getChildren().addAll(status,statusValue);
	Bottom.getChildren().addAll(back,btnCreate);
	AllFields.getChildren().addAll(Identifier,Status,Bottom);
	
	bp.setCenter(AllFields);
	
	/*
	btnCreate.setOnAction(e -> getFXController().showView("serverdoorview"));
	--Listenter to crete a door
	*/
	
	
	return bp;
}
 
开发者ID:CoffeeCodeSwitzerland,项目名称:Lernkartei_2017,代码行数:41,代码来源:CreateDoorView.java

示例2: getKeyspaceField

import javafx.scene.control.TextField; //导入方法依赖的package包/类
private TextField getKeyspaceField(int width) {
    TextField keyspace = new TextField();
    keyspace.setPromptText(localeService.getMessage("ui.menu.file.connect.keyspace.text"));
    keyspace.setAlignment(Pos.TOP_CENTER);
    keyspace.setMinWidth(width - 10);
    keyspace.setMaxWidth(width - 10);
    keyspace.setOnAction(this::handleClick);
    return keyspace;
}
 
开发者ID:Kindrat,项目名称:cassandra-client,代码行数:10,代码来源:NewConnectionBox.java

示例3: getUrlField

import javafx.scene.control.TextField; //导入方法依赖的package包/类
private TextField getUrlField(int width) {
    TextField url = new TextField();
    url.setPromptText(localeService.getMessage("ui.menu.file.connect.url.text"));
    url.setAlignment(Pos.CENTER);
    url.setMinWidth(width - 10);
    url.setMaxWidth(width - 10);
    return url;
}
 
开发者ID:Kindrat,项目名称:cassandra-client,代码行数:9,代码来源:NewConnectionBox.java

示例4: constructContainer

import javafx.scene.control.TextField; //导入方法依赖的package包/类
@Override
public Parent constructContainer()
{
	bp.setId("loginviewbg");
	
	AllFields = new HBox(50);
	AllFields.setAlignment(Pos.CENTER);
	AllFields.setMaxWidth(300);
	AllFields.setPadding(new Insets(20));
	AllFields.setPadding(new Insets(200,0,0,0));
	//AllFields.setMinWidth(740);
	
	Value = new VBox();
	Value.setMinWidth(400);
	Value.setSpacing(35);
	Buttons = new VBox();
	Buttons.setSpacing(5);
	Name = new HBox();
	
	inputName = new TextField();
	inputName.setPromptText("Names der Door");
	inputName.setAlignment(Pos.CENTER_LEFT);
	inputName.setMinWidth(50);
	
	name = new Label("Name");
	removeDoor = new Label("Door l�schen");
	removeStacks = new Label("Enfert den/die Stack/s der Door");
	titel = new Label("Bearbeiten");

	btnRemoveDoor = new AppButton("Entfernen");
	btnRemoveStack = new AppButton("L�schen");
	btnModify = new AppButton("�ndern");
	back = new BackButton(getFXController(),"Abbrechen");
	
	//Buttons.getChildren().addAll(,,btnRemoveStack,back);
	Name.getChildren().addAll(name,inputName);
	Value.getChildren().addAll(Name,removeDoor,removeStacks);
	Buttons.getChildren().addAll(btnModify,btnRemoveStack,btnRemoveDoor,back);
	AllFields.getChildren().addAll(Value,Buttons);
	
	/*inside.setLeft(AllFields);
	inside.setRight(Buttons);*/
	
	bp.setCenter(AllFields);
	
	/*
	btnCreate.setOnAction(e -> getFXController().showView("serverdoorview"));
	--Listenter to crete a door
	*/
	
	
	return bp;
}
 
开发者ID:CoffeeCodeSwitzerland,项目名称:Lernkartei_2017,代码行数:54,代码来源:DMOModifyDoorView.java

示例5: constructContainer

import javafx.scene.control.TextField; //导入方法依赖的package包/类
@Override
public Parent constructContainer()
{
	bp.setId("loginviewbg");
	
	AllFields = new HBox(50);
	AllFields.setAlignment(Pos.CENTER);
	AllFields.setMaxWidth(300);
	AllFields.setPadding(new Insets(20));
	AllFields.setPadding(new Insets(200,0,0,0));
	//AllFields.setMinWidth(740);
	
	Value = new VBox();
	Value.setMinWidth(400);
	Value.setSpacing(35);
	Buttons = new VBox();
	Buttons.setSpacing(5);
	Name = new HBox();
	
	inputName = new TextField();
	inputName.setPromptText("Names der Door");
	inputName.setAlignment(Pos.CENTER_LEFT);
	inputName.setMinWidth(50);
	
	name = new Label("Name");
	removeDoor = new Label("Stack l�schen");
	titel = new Label("Bearbeiten");

	btnRemoveDoor = new AppButton("Entfernen");
	btnRemoveStack = new AppButton("Entfernen");
	btnModify = new AppButton("�ndern");
	back = new BackButton(getFXController(),"Abbrechen");
	
	//Buttons.getChildren().addAll(,,btnRemoveStack,back);
	Name.getChildren().addAll(name,inputName);
	Value.getChildren().addAll(Name,removeDoor);
	Buttons.getChildren().addAll(btnModify,btnRemoveDoor,back);
	AllFields.getChildren().addAll(Value,Buttons);
	
	/*inside.setLeft(AllFields); 
	inside.setRight(Buttons);*/
	
	bp.setCenter(AllFields);
	
	/*
	btnCreate.setOnAction(e -> getFXController().showView("serverdoorview"));
	--Listenter to crete a door
	*/
	
	
	return bp;
}
 
开发者ID:CoffeeCodeSwitzerland,项目名称:Lernkartei_2017,代码行数:53,代码来源:DMOModifyStackView.java

示例6: getUsernameField

import javafx.scene.control.TextField; //导入方法依赖的package包/类
private TextField getUsernameField() {
    TextField username = new TextField();
    username.setPromptText(localeService.getMessage("ui.menu.file.connect.auth.username"));
    username.setAlignment(Pos.CENTER);
    return username;
}
 
开发者ID:Kindrat,项目名称:cassandra-client,代码行数:7,代码来源:AuthCredentialsBox.java

示例7: getPasswordField

import javafx.scene.control.TextField; //导入方法依赖的package包/类
private TextField getPasswordField() {
    TextField username = new TextField();
    username.setPromptText(localeService.getMessage("ui.menu.file.connect.auth.password"));
    username.setAlignment(Pos.CENTER);
    return username;
}
 
开发者ID:Kindrat,项目名称:cassandra-client,代码行数:7,代码来源:AuthCredentialsBox.java


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