Revision: 15110
          http://sourceforge.net/p/skim-app/code/15110
Author:   hofman
Date:     2025-04-10 17:28:07 +0000 (Thu, 10 Apr 2025)
Log Message:
-----------
Movee fonts button to end of notes toolbar, as it is only used for text notes

Modified Paths:
--------------
    trunk/SKNoteToolbarController.m

Modified: trunk/SKNoteToolbarController.m
===================================================================
--- trunk/SKNoteToolbarController.m     2025-04-10 16:46:15 UTC (rev 15109)
+++ trunk/SKNoteToolbarController.m     2025-04-10 17:28:07 UTC (rev 15110)
@@ -97,15 +97,6 @@
     [self updateColorsMenu];
     [[NSUserDefaults standardUserDefaults] addObserver:self 
forKeyPath:SKSwatchColorsKey options:0 context:&SKDefaultsObservationContext];
     
-    fontsButton = [NSSegmentedControl segmentedControlWithImages:@[[NSImage 
imageNamed:SKImageNameToolbarFonts]] 
trackingMode:NSSegmentSwitchTrackingMomentary target:nil 
action:@selector(orderFrontFontPanel:)];
-    [fontsButton setHelp:NSLocalizedString(@"Fonts", @"Tool tip message") 
forSegment:0];
-    [fontsButton setTranslatesAutoresizingMaskIntoConstraints:NO];
-    menu = [NSMenu menu];
-    for (NSInteger i = 9; i < 19; i++) {
-        [menu addItemWithTitle:[NSString stringWithFormat:@"%ld", (long)i] 
action:@selector(selectFontSize:) target:self tag:i];
-    }
-    [fontsButton setMenu:menu forSegment:0];
-    
     linesButton = [NSSegmentedControl segmentedControlWithImages:@[[NSImage 
imageNamed:SKImageNameToolbarLines]] 
trackingMode:NSSegmentSwitchTrackingMomentary target:nil 
action:@selector(orderFrontLineInspector:)];
     [linesButton setHelp:NSLocalizedString(@"Lines", @"Tool tip message") 
forSegment:0];
     [linesButton setTranslatesAutoresizingMaskIntoConstraints:NO];
@@ -128,6 +119,15 @@
     }
     [linesButton setMenu:menu forSegment:0];
     
+    fontsButton = [NSSegmentedControl segmentedControlWithImages:@[[NSImage 
imageNamed:SKImageNameToolbarFonts]] 
trackingMode:NSSegmentSwitchTrackingMomentary target:nil 
action:@selector(orderFrontFontPanel:)];
+    [fontsButton setHelp:NSLocalizedString(@"Fonts", @"Tool tip message") 
forSegment:0];
+    [fontsButton setTranslatesAutoresizingMaskIntoConstraints:NO];
+    menu = [NSMenu menu];
+    for (NSInteger i = 9; i < 19; i++) {
+        [menu addItemWithTitle:[NSString stringWithFormat:@"%ld", (long)i] 
action:@selector(selectFontSize:) target:self tag:i];
+    }
+    [fontsButton setMenu:menu forSegment:0];
+    
     [self validateButtons];
     
     NSView *view = [[NSView alloc] init];
@@ -141,10 +141,10 @@
         [[noteButton centerYAnchor] constraintEqualToAnchor:[view 
centerYAnchor]],
         [[colorsButton leadingAnchor] constraintEqualToAnchor:[noteButton 
trailingAnchor] constant:20.0],
         [[colorsButton centerYAnchor] constraintEqualToAnchor:[noteButton 
centerYAnchor]],
-        [[fontsButton leadingAnchor] constraintEqualToAnchor:[colorsButton 
trailingAnchor] constant:8.0],
-        [[fontsButton centerYAnchor] constraintEqualToAnchor:[noteButton 
centerYAnchor]],
-        [[linesButton leadingAnchor] constraintEqualToAnchor:[fontsButton 
trailingAnchor] constant:8.0],
-        [[linesButton centerYAnchor] constraintEqualToAnchor:[noteButton 
centerYAnchor]]
+        [[linesButton leadingAnchor] constraintEqualToAnchor:[colorsButton 
trailingAnchor] constant:8.0],
+        [[linesButton centerYAnchor] constraintEqualToAnchor:[noteButton 
centerYAnchor]],
+        [[fontsButton leadingAnchor] constraintEqualToAnchor:[linesButton 
trailingAnchor] constant:8.0],
+        [[fontsButton centerYAnchor] constraintEqualToAnchor:[noteButton 
centerYAnchor]]
     ];
     [NSLayoutConstraint activateConstraints:constraints];
     

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Skim-app-commit mailing list
Skim-app-commit@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to