Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/keenwrite.git

Adjust initial window sizes

AuthorDaveJarvis <email>
Date2020-07-02 16:33:49 GMT-0700
Commit487dbcd2bb52cecc1a707dab478f771209cd6502
Parent1390668
src/main/java/com/scrivenvar/MainWindow.java
splitPane.setDividerPositions(
- getFloat( K_PANE_SPLIT_DEFINITION, .10f ),
- getFloat( K_PANE_SPLIT_EDITOR, .45f ),
- getFloat( K_PANE_SPLIT_PREVIEW, .45f ) );
+ getFloat( K_PANE_SPLIT_DEFINITION, .22f ),
+ getFloat( K_PANE_SPLIT_EDITOR, .60f ),
+ getFloat( K_PANE_SPLIT_PREVIEW, .18f ) );
getDefinitionPane().prefHeightProperty()
.bind( splitPane.heightProperty() );
final BorderPane borderPane = new BorderPane();
- borderPane.setPrefSize( 1024, 800 );
+ borderPane.setPrefSize( 1280, 800 );
borderPane.setTop( createMenuBar() );
borderPane.setBottom( getStatusBar() );
// Force preview pane refresh on Windows.
- splitPane.getDividers().get( 1 ).positionProperty().addListener(
- ( l, oValue, nValue ) -> runLater(
- () -> {
- if( SystemUtils.IS_OS_WINDOWS ) {
- getPreviewPane().getScrollPane().repaint();
- }
- }
- )
- );
+ if( SystemUtils.IS_OS_WINDOWS ) {
+ splitPane.getDividers().get( 1 ).positionProperty().addListener(
+ ( l, oValue, nValue ) -> runLater(
+ () -> getPreviewPane().getScrollPane().repaint()
+ )
+ );
+ }
return new Scene( borderPane );
Delta11 lines added, 13 lines removed, 2-line decrease