Skip to content

Commit 9d1de48

Browse files
ddamkeddamke
authored andcommitted
make tabs and overall view smaller
1 parent 7c46fe9 commit 9d1de48

File tree

2 files changed

+41
-68
lines changed

2 files changed

+41
-68
lines changed

src/main/resources/css/settingsv2.css

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@
1515
-fx-spacing: 15px;
1616

1717
}
18-
18+
.tab-pane > .tab-header-area > .headers-region > .tab > .tab-container {
19+
-fx-rotate: 90;
20+
}
1921

2022
.tab-pane .tab-header-area .tab-header-background {
2123
-fx-opacity: 0;
@@ -24,9 +26,10 @@
2426

2527
.tab-pane .tab
2628
{
29+
-fx-translate-y: -50;
2730
-fx-background-color: lightgrey;
28-
-fx-pref-height: 100;
29-
-fx-pref-width: 70;
31+
-fx-pref-height: 170;
32+
-fx-pref-width: 40;
3033
}
3134

3235
.tab-pane:focused > .tab-header-area > .headers-region > .tab:selected .focus-indicator {
@@ -37,15 +40,13 @@
3740
{
3841
-fx-background-color: white;
3942
}
43+
4044
.tab-pane .tab:hover
4145
{
46+
-fx-border-style: hidden hidden solid hidden;
47+
-fx-border-color: black;
4248
-fx-border-width: 2;
43-
-fx-border-color: blue;
44-
-fx-border-style: solid hidden hidden hidden;
45-
4649
}
47-
48-
4950
.button{
5051
-fx-background-color: white;
5152
-fx-border-color: lightgrey;
@@ -54,7 +55,6 @@
5455
}
5556
.button:hover{
5657
-fx-border-color: grey;
57-
5858
}
5959
.color-picker{
6060
-fx-background-color: white;

src/main/resources/layouts/settings.fxml

Lines changed: 32 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,15 @@
3636
<?import javafx.scene.text.Font?>
3737
<?import javafx.scene.text.Text?>
3838

39-
<AnchorPane fx:id="settingsRoot" focusTraversable="true" prefHeight="467.0" prefWidth="503.0" style="-fx-background-color: white;" xmlns="http://javafx.com/javafx/8.0.171" xmlns:fx="http://javafx.com/fxml/1" fx:controller="de.doubleslash.keeptime.view.SettingsController">
39+
<AnchorPane fx:id="settingsRoot" focusTraversable="true" prefHeight="285.0" prefWidth="514.0" style="-fx-background-color: white;" xmlns="http://javafx.com/javafx/8.0.171" xmlns:fx="http://javafx.com/fxml/1" fx:controller="de.doubleslash.keeptime.view.SettingsController">
4040
<children>
41-
<TabPane layoutY="6.0" prefHeight="459.0" prefWidth="500.0" side="LEFT" stylesheets="@../css/settingsv2.css" tabClosingPolicy="UNAVAILABLE" tabMinHeight="100.0" tabMinWidth="40.0">
41+
<TabPane layoutY="6.0" prefHeight="355.0" prefWidth="558.0" rotateGraphic="true" side="LEFT" stylesheets="@../css/settingsv2.css" tabClosingPolicy="UNAVAILABLE">
4242
<tabs>
43-
<Tab closable="false">
43+
<Tab text="Color">
4444
<content>
45-
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="475.0" prefWidth="501.0">
45+
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="459.0" prefWidth="350.0">
4646
<children>
47-
<VBox layoutX="20.0" layoutY="20.0" prefHeight="393.0" prefWidth="486.0" spacing="5.0" styleClass="menuBorder">
47+
<VBox layoutY="20.0" prefHeight="393.0" prefWidth="510.0" spacing="5.0" styleClass="menuBorder">
4848
<children>
4949
<Group>
5050
<children>
@@ -161,19 +161,14 @@
161161
</AnchorPane>
162162
</content>
163163
<graphic>
164-
<HBox spacing="5.0" styleClass="HBox" stylesheets="@../css/settingsv2.css">
165-
<children>
166-
<Region fx:id="colorIcon" prefHeight="25.0" prefWidth="25.0" />
167-
<Label contentDisplay="TOP" prefWidth="75.0" text="Color" />
168-
</children>
169-
</HBox>
164+
<Region fx:id="colorIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
170165
</graphic>
171166
</Tab>
172-
<Tab>
167+
<Tab text="Layout">
173168
<content>
174169
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0">
175170
<children>
176-
<VBox layoutX="20.0" layoutY="20.0" prefHeight="412.0" prefWidth="483.0" spacing="5.0">
171+
<VBox layoutY="20.0" prefHeight="412.0" prefWidth="483.0" spacing="5.0">
177172
<children>
178173
<Group>
179174
<children>
@@ -245,19 +240,14 @@
245240
</AnchorPane>
246241
</content>
247242
<graphic>
248-
<HBox spacing="5.0" styleClass="HBox" stylesheets="@../css/settingsv2.css">
249-
<children>
250-
<Region fx:id="layoutIcon" prefHeight="25.0" prefWidth="25.0" />
251-
<Label prefWidth="75.0" text="Layout" />
252-
</children>
253-
</HBox>
243+
<Region fx:id="layoutIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
254244
</graphic>
255245
</Tab>
256-
<Tab>
246+
<Tab text="General">
257247
<content>
258248
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="420.0" prefWidth="407.0">
259249
<children>
260-
<VBox layoutX="20.0" layoutY="20.0" prefHeight="419.0" prefWidth="482.0" spacing="5.0" stylesheets="@../css/menu.css">
250+
<VBox layoutY="20.0" prefHeight="419.0" prefWidth="482.0" spacing="5.0" stylesheets="@../css/menu.css">
261251
<children>
262252
<Group>
263253
<children>
@@ -371,38 +361,33 @@
371361
</AnchorPane>
372362
</content>
373363
<graphic>
374-
<HBox spacing="5.0" styleClass="HBox" stylesheets="@../css/settingsv2.css">
375-
<children>
376-
<Region fx:id="generalIcon" prefHeight="25.0" prefWidth="25.0" />
377-
<Label prefWidth="75.0" text="General" />
378-
</children>
379-
</HBox>
364+
<Region fx:id="generalIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
380365
</graphic>
381366
</Tab>
382-
<Tab>
367+
<Tab text="Import/Export">
383368
<content>
384369
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="489.0" prefWidth="452.0">
385370
<children>
386-
<VBox layoutX="20.0" layoutY="19.0" prefHeight="376.0" prefWidth="343.0" spacing="5.0">
371+
<VBox layoutY="20.0" prefHeight="357.0" prefWidth="380.0" spacing="5.0">
387372
<children>
388373
<Group>
389374
<children>
390-
<VBox alignment="BOTTOM_RIGHT" layoutX="30.0" layoutY="81.0" prefHeight="164.0" prefWidth="370.0" styleClass="settingsBorder" stylesheets="@../css/settingsv2.css">
375+
<VBox alignment="BOTTOM_RIGHT" layoutX="30.0" layoutY="81.0" prefHeight="139.0" prefWidth="370.0" styleClass="settingsBorder" stylesheets="@../css/settingsv2.css">
391376
<children>
392377
<HBox prefHeight="18.0" prefWidth="431.0">
393378
<children>
394-
<Text strokeType="OUTSIDE" strokeWidth="0.0" text="Import">
379+
<Text strokeType="OUTSIDE" strokeWidth="0.0" text="Import" wrappingWidth="47.017578125">
395380
<font>
396381
<Font name="System Bold" size="12.0" />
397382
</font></Text>
398383
</children>
399384
</HBox>
400-
<HBox prefHeight="88.0" prefWidth="470.0">
385+
<HBox prefHeight="73.0" prefWidth="368.0">
401386
<children>
402387
<Label prefHeight="72.0" prefWidth="368.0" text="Import previously exported .sql file. This will overwrite the currently used database contents. You will need to restart the application after this action. If you proceed you need to select the previouls exported .sql file." textOverrun="CLIP" wrapText="true" HBox.hgrow="NEVER" />
403388
</children>
404389
</HBox>
405-
<HBox alignment="BOTTOM_RIGHT" prefHeight="43.0" prefWidth="428.0">
390+
<HBox alignment="BOTTOM_RIGHT" prefHeight="31.0" prefWidth="368.0">
406391
<children>
407392
<Button fx:id="importButton" alignment="TOP_LEFT" mnemonicParsing="false" text="Import">
408393
<font>
@@ -417,7 +402,7 @@
417402
</Group>
418403
<Group layoutX="10.0" layoutY="10.0" styleClass="settingsBorder" stylesheets="@../css/settingsv2.css">
419404
<children>
420-
<VBox alignment="BOTTOM_RIGHT" prefHeight="165.0" prefWidth="368.0" styleClass="settingsBorder" stylesheets="@../css/settingsv2.css">
405+
<VBox alignment="BOTTOM_RIGHT" prefHeight="110.0" prefWidth="368.0" styleClass="settingsBorder" stylesheets="@../css/settingsv2.css">
421406
<children>
422407
<HBox prefHeight="19.0" prefWidth="434.0">
423408
<children>
@@ -427,7 +412,7 @@
427412
</font></Text>
428413
</children>
429414
</HBox>
430-
<HBox prefHeight="94.0" prefWidth="366.0">
415+
<HBox prefHeight="42.0" prefWidth="366.0">
431416
<children>
432417
<Label text="Export your current Data to an Sql script. This is needed if you go from the Snapshot-1.2.0-KeepTimeto the recent release version. " wrapText="true" />
433418
</children>
@@ -454,28 +439,26 @@
454439
</AnchorPane>
455440
</content>
456441
<graphic>
457-
<HBox spacing="5.0" styleClass="HBox" stylesheets="@../css/settingsv2.css">
458-
<children>
459-
<Region fx:id="importexportIcon" prefHeight="25.0" prefWidth="25.0" />
460-
<Label prefWidth="75.0" text="Import/Export" />
461-
</children>
462-
</HBox>
442+
<Region fx:id="importexportIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
463443
</graphic>
464444
</Tab>
465-
<Tab>
445+
<Tab text="Licenses">
466446
<content>
467447
<AnchorPane layoutX="20.0" layoutY="20.0" minHeight="0.0" minWidth="0.0" prefHeight="438.0" prefWidth="489.0">
468448
<children>
469-
<VBox layoutX="20.0" layoutY="20.0" prefHeight="387.0" prefWidth="376.0" spacing="5.0">
449+
<VBox layoutY="20.0" prefHeight="387.0" prefWidth="376.0" spacing="5.0">
470450
<children>
471451
<Group />
472-
<VBox prefHeight="354.0" prefWidth="375.0" spacing="5.0" stylesheets="@../css/settingsv2.css">
452+
<VBox prefHeight="354.0" prefWidth="378.0" spacing="5.0" stylesheets="@../css/settingsv2.css">
473453
<children>
474454
<Label fx:id="thirdPartyLabel" text="Third party software">
475455
<font>
476456
<Font name="System Bold" size="12.0" />
477457
</font></Label>
478-
<TableView fx:id="licenseTableView" fixedCellSize="0.0" focusTraversable="false" prefHeight="283.0" prefWidth="357.0" />
458+
<TableView fx:id="licenseTableView" fixedCellSize="0.0" focusTraversable="false" prefHeight="257.0" prefWidth="371.0">
459+
<columnResizePolicy>
460+
<TableView fx:constant="CONSTRAINED_RESIZE_POLICY" />
461+
</columnResizePolicy></TableView>
479462
</children>
480463
</VBox>
481464
</children>
@@ -487,19 +470,14 @@
487470
</AnchorPane>
488471
</content>
489472
<graphic>
490-
<HBox spacing="5.0">
491-
<children>
492-
<Region fx:id="licensesIcon" prefHeight="25.0" prefWidth="25.0" />
493-
<Label prefWidth="75.0" text="Licenses" />
494-
</children>
495-
</HBox>
473+
<Region fx:id="licensesIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
496474
</graphic>
497475
</Tab>
498-
<Tab>
476+
<Tab text="About">
499477
<content>
500478
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="446.0" prefWidth="501.0" stylesheets="@../css/settingsv2.css">
501479
<children>
502-
<Pane fx:id="mainContainer" layoutX="-20.0" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="492.0" prefWidth="478.0" styleClass="tab-pane" stylesheets="@../css/settingsv2.css">
480+
<Pane fx:id="mainContainer" layoutX="-33.0" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="492.0" prefWidth="478.0" styleClass="tab-pane" stylesheets="@../css/settingsv2.css">
503481
<children>
504482
<Label fx:id="keepTimeLabel" layoutX="138.0" layoutY="14.0" text="KeepTime">
505483
<font>
@@ -564,12 +542,7 @@
564542
</AnchorPane>
565543
</content>
566544
<graphic>
567-
<HBox spacing="5.0" styleClass="HBox" stylesheets="@../css/settingsv2.css">
568-
<children>
569-
<Region fx:id="aboutIcon" prefHeight="25.0" prefWidth="25.0" />
570-
<Label prefWidth="75.0" text="About" />
571-
</children>
572-
</HBox>
545+
<Region fx:id="aboutIcon" prefHeight="15.0" prefWidth="15.0" rotate="-90.0" />
573546
</graphic>
574547
</Tab>
575548
</tabs>

0 commit comments

Comments
 (0)