@@ -29,6 +29,7 @@ namespace jorts {
2929 }
3030
3131 public int64 latest_zoom;
32+ private bool squiggly_mode_active = false ;
3233
3334 public override void startup () {
3435 base . startup ();
@@ -63,10 +64,12 @@ namespace jorts {
6364 }
6465
6566 static construct {
66- gsettings = new GLib .Settings (jorts. Constants . app_rdnn);
67+ // gsettings = new GLib.Settings (jorts.Constants.app_rdnn);
6768 }
6869
6970 construct {
71+ // this.squiggly_mode_active = gsettings.get_boolean ("squiggly_mode_active");
72+
7073 var quit_action = new SimpleAction (" quit" , null );
7174 set_accels_for_action (" app.quit" , {" <Control>q" });
7275 add_action (quit_action);
@@ -116,6 +119,25 @@ namespace jorts {
116119 MainWindow note = (MainWindow )get_active_window ();
117120 note. zoom_in ();
118121 });
122+ var toggle_squiggly = new SimpleAction (" toggle_squiggly" , null );
123+ set_accels_for_action (" app.toggle_squiggly" , { " <Control>H" , null });
124+ add_action (toggle_squiggly);
125+ toggle_squiggly. activate. connect (() = > {
126+ if (this . squiggly_mode_active) {
127+ foreach (var window in open_notes) {
128+ window. remove_css_class (" squiggly" );
129+ }
130+ this . squiggly_mode_active = false ;
131+ }
132+ else {
133+ foreach (var window in open_notes) {
134+ window. add_css_class (" squiggly" );
135+ }
136+ this . squiggly_mode_active = true ;
137+ }
138+ // this.squiggly_mode_active = gsettings.set_boolean ("squiggly_mode_active", this.squiggly_mode_active);
139+ });
140+
119141
120142 }
121143
@@ -170,6 +192,9 @@ namespace jorts {
170192 }
171193
172194
195+
196+
197+
173198 // the thing that
174199 public void init_all_notes () {
175200 Gee . ArrayList<noteData> loaded_data = jorts. Stash . load_from_stash();
0 commit comments