--- a/TextView.st Thu Apr 21 06:44:55 2016 +0200
+++ b/TextView.st Fri Apr 22 06:42:13 2016 +0200
@@ -2025,7 +2025,7 @@
changeFont
"pop up a fontPanel to change font"
- |newFont fp|
+ |newFont fp userPrefs fontPrefs newFontPrefs|
self withWaitCursorDo:[
fp := FontPanel new.
@@ -2037,10 +2037,14 @@
fp changeFontInAllViews ifTrue:[
"/ user checked this box - change the defaults,
"/ and update all other textviews now.
-
+ userPrefs := UserPreferences current.
+ fontPrefs := userPrefs fontPreferences.
+ fontPrefs isNil ifTrue:[ fontPrefs := newFontPrefs := Dictionary new ].
+
TextView defaultFont:newFont.
- UserPreferences current fontPreferences
- at:#Text put:(newFont storeString).
+ fontPrefs at:#Text put:(newFont storeString).
+ newFontPrefs notNil ifTrue:[ userPrefs fontPreferences:newFontPrefs ].
+ userPrefs beModified.
DebugView newDebugger.
TextView allSubInstances do:[:v |
v font:newFont