Created
March 10, 2020 17:12
-
-
Save ArchdukeTim/b58ad3bc928d90e4840418caa1fbd712 to your computer and use it in GitHub Desktop.
CS3733 Starter Code
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package edu.wpi.teamname; | |
import javafx.application.Application; | |
import javafx.scene.Scene; | |
import javafx.scene.control.Button; | |
import javafx.scene.control.Label; | |
import javafx.scene.layout.BorderPane; | |
import javafx.stage.Stage; | |
public class App extends Application { | |
@Override | |
public void init() {} | |
@Override | |
public void start(Stage primaryStage) { | |
Label label = new Label("Text"); | |
label.setId("textLabel"); | |
label.setVisible(false); | |
Button button = new Button("My Button"); | |
button.setId("showTextButton"); | |
button.setOnAction((e) -> label.setVisible(true)); | |
BorderPane root = new BorderPane(); | |
root.setRight(label); | |
root.setLeft(button); | |
Scene scene = new Scene(root, 200, 100); | |
primaryStage.setScene(scene); | |
primaryStage.show(); | |
} | |
@Override | |
public void stop() {} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package edu.wpi.teamname; | |
public class Main { | |
public static void main(String[] args) { | |
App.launch(App.class, args); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment