SSCE:
import javafx.application.Application;
import javafx.scene.Group;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.Tooltip;
import javafx.stage.Stage;
public class DisabledTooltips extends Application
{
@Override
public void start( final Stage primaryStage )
{
final Button btn = new Button( "Hit me!" );
final Tooltip tip = new Tooltip( "I am informative!" );
btn.setTooltip( tip );
primaryStage.setScene( new Scene( new Group( btn ) ) );
primaryStage.sizeToScene();
primaryStage.show();
}
public static void main( final String[] args )
{
launch( args );
}
}
The button gets scaled up to the Scene size. Furthermore the scaled image is of bad quality and the hit area of the button is still as if not scaled (can be verified by trying to trigger the tooltip). Upon Stage resize, the button gets resized to its preferred size.
import javafx.application.Application;
import javafx.scene.Group;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.Tooltip;
import javafx.stage.Stage;
public class DisabledTooltips extends Application
{
@Override
public void start( final Stage primaryStage )
{
final Button btn = new Button( "Hit me!" );
final Tooltip tip = new Tooltip( "I am informative!" );
btn.setTooltip( tip );
primaryStage.setScene( new Scene( new Group( btn ) ) );
primaryStage.sizeToScene();
primaryStage.show();
}
public static void main( final String[] args )
{
launch( args );
}
}
The button gets scaled up to the Scene size. Furthermore the scaled image is of bad quality and the hit area of the button is still as if not scaled (can be verified by trying to trigger the tooltip). Upon Stage resize, the button gets resized to its preferred size.