<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p><font size="4">Hi Luciano,</font><br>
</p>
<div class="moz-cite-prefix">Le 05/05/2022 à 08:08, Luciano
Notarfrancesco a écrit :<br>
</div>
<blockquote type="cite"
cite="mid:CAL5GDypJ+fhAdPrCeDpHMxsfCopgkew6jGR16uzQY7BkHHCHTQ@mail.gmail.com">
<div>PreferenceNG class>>#detectType: is intended to be used
for importing the old preferences and will later be removed? I
see it is inconsistent with the initialization method that just
sets </div>
</blockquote>
<p>No it will not be removed. It is needed when instantiating the
default preferences whose data are in Array like:</p>
<p><font face="monospace" color="#97082d">cuisDefaultsFont<br>
^ #( <br>
# (aaFontsColormapDepth 4)<br>
#(cacheTrueTypeGlyphs true )<br>
#(loadOnlyLatinGlyphData true )<br>
#(properDisplayAlphaForFonts false ) <br>
#(subPixelRenderColorFonts true )<br>
)</font></p>
<blockquote type="cite"
cite="mid:CAL5GDypJ+fhAdPrCeDpHMxsfCopgkew6jGR16uzQY7BkHHCHTQ@mail.gmail.com">
<div>type to 'aValue class' if aType is nil. To ensure
consistency, the initialization method could call #detectType:,
unless it's going to be removed. This is specially important for
Booleans, </div>
</blockquote>
<p>Good catch. Indeed the initialization should use the method
detectType: when necessary. Fixed<br>
</p>
<blockquote type="cite"
cite="mid:CAL5GDypJ+fhAdPrCeDpHMxsfCopgkew6jGR16uzQY7BkHHCHTQ@mail.gmail.com">
<div>otherwise the preference will be stuck in true or false. And
should we set the type to the value class or species? Anyway,
I'm not sure it's a good idea to do this automatic detection of
</div>
</blockquote>
<blockquote type="cite"
cite="mid:CAL5GDypJ+fhAdPrCeDpHMxsfCopgkew6jGR16uzQY7BkHHCHTQ@mail.gmail.com">
<div>type, maybe it would be better to just leave it in nil.</div>
</blockquote>
<p>I am not sure either. We can make it to evolve later.<br>
</p>
<blockquote type="cite"
cite="mid:CAL5GDypJ+fhAdPrCeDpHMxsfCopgkew6jGR16uzQY7BkHHCHTQ@mail.gmail.com">
<div><br>
</div>
<div>Also, PreferenceNG>>#printOn: capitalizes the name of
the preference. Since this name is used as a key to identify the
preference, I think it's better to show it as it is without
capitalization.</div>
</blockquote>
<p>Yes you are right. Now it prints as a symbol:</p>
<p><font face="monospace" color="#97082d"> PreferenceNG
(#haloHandleSize = BlockClosure::[closure] in PreferenceNG
class>>installMiscPreferences) </font><br>
</p>
<p>Hilaire<br>
</p>
<pre class="moz-signature" cols="72">--
GNU Dr. Geo
<a class="moz-txt-link-freetext" href="http://drgeo.eu">http://drgeo.eu</a>
<a class="moz-txt-link-freetext" href="http://blog.drgeo.eu">http://blog.drgeo.eu</a></pre>
</body>
</html>