FontTest depends on curent styles

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

FontTest depends on curent styles

Andrey Larionov
Two test in FontTest assumes what TextStyle>>default will answer a
some Accuny font with some size. But if we override default font -
test will fail. I'll try to find solution and fix, but new vm and
image crashed during debuging.
I think solution will be to create corresponding TextStyle for test.

Also i'm a newbie and can some clarify what is DefaultTextStyle? It
not declared as instance or class variable.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Mariano Martinez Peck


On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]> wrote:
Two test in FontTest assumes what TextStyle>>default will answer a
some Accuny font with some size. But if we override default font -
test will fail. I'll try to find solution and fix, but new vm and
image crashed during debuging.
I think solution will be to create corresponding TextStyle for test.

Also i'm a newbie and can some clarify what is DefaultTextStyle? It
not declared as instance or class variable.

I am also a but newbie but I think that's a symbol Is it actually #DefaultTextStyle ?

If true, yes, it would probably be a symbol. A symbol, as Squeak By Example says is:

"
Symbols are like Strings, in that they contain a sequence of characters.
    However, unlike a string, a literal symbol is guaranteed to be globally
    unique. There is only one Symbol object #Hello but there may be
    multiple String objects with the value 'Hello'.
"

See SBE for more documentation.

However, if there is something that it is not a class neither a class variable, it can be a global variable. For example, do a expect it of Smalltalk. You may think Smalltalk is a class, but it doesn't. It is global variable. Indeed it is an object of SystemDirectory.

Cheers,

Mariano
 


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Andrey Larionov
Is symbol may contain a value?

2009/4/8 Mariano Martinez Peck <[hidden email]>:

>
>
> On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]>
> wrote:
>>
>> Two test in FontTest assumes what TextStyle>>default will answer a
>> some Accuny font with some size. But if we override default font -
>> test will fail. I'll try to find solution and fix, but new vm and
>> image crashed during debuging.
>> I think solution will be to create corresponding TextStyle for test.
>>
>> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
>> not declared as instance or class variable.
>
> I am also a but newbie but I think that's a symbol Is it actually
> #DefaultTextStyle ?
>
> If true, yes, it would probably be a symbol. A symbol, as Squeak By Example
> says is:
>
> "
> Symbols are like Strings, in that they contain a sequence of characters.
>     However, unlike a string, a literal symbol is guaranteed to be globally
>     unique. There is only one Symbol object #Hello but there may be
>     multiple String objects with the value 'Hello'.
> "
>
> See SBE for more documentation.
>
> However, if there is something that it is not a class neither a class
> variable, it can be a global variable. For example, do a expect it of
> Smalltalk. You may think Smalltalk is a class, but it doesn't. It is global
> variable. Indeed it is an object of SystemDirectory.
>
> Cheers,
>
> Mariano
>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Mariano Martinez Peck


On Tue, Apr 7, 2009 at 10:47 PM, Andrey Larionov <[hidden email]> wrote:
Is symbol may contain a value?

As I understand it, the symbol is the value itself. Suppose you use #something. Everywhere in the image you use #something, you will be talking about the same symbol. They don't have a dynamic value as String. I mean, in String you set it a value. In symbols, they already are the value. They are literal.

I don't know If I am being clear enough.

Greetings,

Mariano
 

2009/4/8 Mariano Martinez Peck <[hidden email]>:
>
>
> On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]>
> wrote:
>>
>> Two test in FontTest assumes what TextStyle>>default will answer a
>> some Accuny font with some size. But if we override default font -
>> test will fail. I'll try to find solution and fix, but new vm and
>> image crashed during debuging.
>> I think solution will be to create corresponding TextStyle for test.
>>
>> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
>> not declared as instance or class variable.
>
> I am also a but newbie but I think that's a symbol Is it actually
> #DefaultTextStyle ?
>
> If true, yes, it would probably be a symbol. A symbol, as Squeak By Example
> says is:
>
> "
> Symbols are like Strings, in that they contain a sequence of characters.
>     However, unlike a string, a literal symbol is guaranteed to be globally
>     unique. There is only one Symbol object #Hello but there may be
>     multiple String objects with the value 'Hello'.
> "
>
> See SBE for more documentation.
>
> However, if there is something that it is not a class neither a class
> variable, it can be a global variable. For example, do a expect it of
> Smalltalk. You may think Smalltalk is a class, but it doesn't. It is global
> variable. Indeed it is an object of SystemDirectory.
>
> Cheers,
>
> Mariano
>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Stéphane Ducasse
A symbol is a unique string. Its value is itself. A symbol is not a  
variable which has a value.
But a variable may contain a value.

Have fun learning and do not hesitate asking questions.

Stef

On Apr 8, 2009, at 3:56 AM, Mariano Martinez Peck wrote:

>
>
> On Tue, Apr 7, 2009 at 10:47 PM, Andrey Larionov  
> <[hidden email]> wrote:
> Is symbol may contain a value?
>
> As I understand it, the symbol is the value itself. Suppose you use  
> #something. Everywhere in the image you use #something, you will be  
> talking about the same symbol. They don't have a dynamic value as  
> String. I mean, in String you set it a value. In symbols, they  
> already are the value. They are literal.
>
> I don't know If I am being clear enough.
>
> Greetings,
>
> Mariano
>
>
> 2009/4/8 Mariano Martinez Peck <[hidden email]>:
> >
> >
> > On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]
> >
> > wrote:
> >>
> >> Two test in FontTest assumes what TextStyle>>default will answer a
> >> some Accuny font with some size. But if we override default font -
> >> test will fail. I'll try to find solution and fix, but new vm and
> >> image crashed during debuging.
> >> I think solution will be to create corresponding TextStyle for  
> test.
> >>
> >> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
> >> not declared as instance or class variable.
> >
> > I am also a but newbie but I think that's a symbol Is it actually
> > #DefaultTextStyle ?
> >
> > If true, yes, it would probably be a symbol. A symbol, as Squeak  
> By Example
> > says is:
> >
> > "
> > Symbols are like Strings, in that they contain a sequence of  
> characters.
> >     However, unlike a string, a literal symbol is guaranteed to be  
> globally
> >     unique. There is only one Symbol object #Hello but there may be
> >     multiple String objects with the value 'Hello'.
> > "
> >
> > See SBE for more documentation.
> >
> > However, if there is something that it is not a class neither a  
> class
> > variable, it can be a global variable. For example, do a expect it  
> of
> > Smalltalk. You may think Smalltalk is a class, but it doesn't. It  
> is global
> > variable. Indeed it is an object of SystemDirectory.
> >
> > Cheers,
> >
> > Mariano
> >
> >>
> >> _______________________________________________
> >> Pharo-project mailing list
> >> [hidden email]
> >> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
> >
> >
> > _______________________________________________
> > Pharo-project mailing list
> > [hidden email]
> > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
> >
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Adrian Lienhard
In reply to this post by Mariano Martinez Peck
Hi Andrey,

#DefaultTextStyle is a key in TextConstants.
You can find all usages of DefaultTextStyle if you search for its  
senders (select it and ctrl-n).

HTH,
Adrian

On Apr 8, 2009, at 03:56 , Mariano Martinez Peck wrote:

> On Tue, Apr 7, 2009 at 10:47 PM, Andrey Larionov  
> <[hidden email]>wrote:
>
>> Is symbol may contain a value?
>>
>
> As I understand it, the symbol is the value itself. Suppose you use
> #something. Everywhere in the image you use #something, you will be  
> talking
> about the same symbol. They don't have a dynamic value as String. I  
> mean, in
> String you set it a value. In symbols, they already are the value.  
> They are
> literal.
>
> I don't know If I am being clear enough.
>
> Greetings,
>
> Mariano
>
>
>>
>> 2009/4/8 Mariano Martinez Peck <[hidden email]>:
>>>
>>>
>>> On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]
>>> >
>>> wrote:
>>>>
>>>> Two test in FontTest assumes what TextStyle>>default will answer a
>>>> some Accuny font with some size. But if we override default font -
>>>> test will fail. I'll try to find solution and fix, but new vm and
>>>> image crashed during debuging.
>>>> I think solution will be to create corresponding TextStyle for  
>>>> test.
>>>>
>>>> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
>>>> not declared as instance or class variable.
>>>
>>> I am also a but newbie but I think that's a symbol Is it actually
>>> #DefaultTextStyle ?
>>>
>>> If true, yes, it would probably be a symbol. A symbol, as Squeak By
>> Example
>>> says is:
>>>
>>> "
>>> Symbols are like Strings, in that they contain a sequence of  
>>> characters.
>>>    However, unlike a string, a literal symbol is guaranteed to be
>> globally
>>>    unique. There is only one Symbol object #Hello but there may be
>>>    multiple String objects with the value 'Hello'.
>>> "
>>>
>>> See SBE for more documentation.
>>>
>>> However, if there is something that it is not a class neither a  
>>> class
>>> variable, it can be a global variable. For example, do a expect it  
>>> of
>>> Smalltalk. You may think Smalltalk is a class, but it doesn't. It is
>> global
>>> variable. Indeed it is an object of SystemDirectory.
>>>
>>> Cheers,
>>>
>>> Mariano
>>>
>>>>
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Andrey Larionov
Thanks, Adrian.

On Wed, Apr 8, 2009 at 10:58, Adrian Lienhard <[hidden email]> wrote:

> Hi Andrey,
>
> #DefaultTextStyle is a key in TextConstants.
> You can find all usages of DefaultTextStyle if you search for its
> senders (select it and ctrl-n).
>
> HTH,
> Adrian
>
> On Apr 8, 2009, at 03:56 , Mariano Martinez Peck wrote:
>
>> On Tue, Apr 7, 2009 at 10:47 PM, Andrey Larionov
>> <[hidden email]>wrote:
>>
>>> Is symbol may contain a value?
>>>
>>
>> As I understand it, the symbol is the value itself. Suppose you use
>> #something. Everywhere in the image you use #something, you will be
>> talking
>> about the same symbol. They don't have a dynamic value as String. I
>> mean, in
>> String you set it a value. In symbols, they already are the value.
>> They are
>> literal.
>>
>> I don't know If I am being clear enough.
>>
>> Greetings,
>>
>> Mariano
>>
>>
>>>
>>> 2009/4/8 Mariano Martinez Peck <[hidden email]>:
>>>>
>>>>
>>>> On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]
>>>> >
>>>> wrote:
>>>>>
>>>>> Two test in FontTest assumes what TextStyle>>default will answer a
>>>>> some Accuny font with some size. But if we override default font -
>>>>> test will fail. I'll try to find solution and fix, but new vm and
>>>>> image crashed during debuging.
>>>>> I think solution will be to create corresponding TextStyle for
>>>>> test.
>>>>>
>>>>> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
>>>>> not declared as instance or class variable.
>>>>
>>>> I am also a but newbie but I think that's a symbol Is it actually
>>>> #DefaultTextStyle ?
>>>>
>>>> If true, yes, it would probably be a symbol. A symbol, as Squeak By
>>> Example
>>>> says is:
>>>>
>>>> "
>>>> Symbols are like Strings, in that they contain a sequence of
>>>> characters.
>>>>    However, unlike a string, a literal symbol is guaranteed to be
>>> globally
>>>>    unique. There is only one Symbol object #Hello but there may be
>>>>    multiple String objects with the value 'Hello'.
>>>> "
>>>>
>>>> See SBE for more documentation.
>>>>
>>>> However, if there is something that it is not a class neither a
>>>> class
>>>> variable, it can be a global variable. For example, do a expect it
>>>> of
>>>> Smalltalk. You may think Smalltalk is a class, but it doesn't. It is
>>> global
>>>> variable. Indeed it is an object of SystemDirectory.
>>>>
>>>> Cheers,
>>>>
>>>> Mariano
>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Pharo-project mailing list
>>>>> [hidden email]
>>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>>
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: FontTest depends on curent styles

Andrey Larionov
Yesterday i start inspection of test fail. I was wrong. So i try to
find problem and fix it. It will a good lesson for begginer.

On Wed, Apr 8, 2009 at 15:08, Andrey Larionov <[hidden email]> wrote:

> Thanks, Adrian.
>
> On Wed, Apr 8, 2009 at 10:58, Adrian Lienhard <[hidden email]> wrote:
>> Hi Andrey,
>>
>> #DefaultTextStyle is a key in TextConstants.
>> You can find all usages of DefaultTextStyle if you search for its
>> senders (select it and ctrl-n).
>>
>> HTH,
>> Adrian
>>
>> On Apr 8, 2009, at 03:56 , Mariano Martinez Peck wrote:
>>
>>> On Tue, Apr 7, 2009 at 10:47 PM, Andrey Larionov
>>> <[hidden email]>wrote:
>>>
>>>> Is symbol may contain a value?
>>>>
>>>
>>> As I understand it, the symbol is the value itself. Suppose you use
>>> #something. Everywhere in the image you use #something, you will be
>>> talking
>>> about the same symbol. They don't have a dynamic value as String. I
>>> mean, in
>>> String you set it a value. In symbols, they already are the value.
>>> They are
>>> literal.
>>>
>>> I don't know If I am being clear enough.
>>>
>>> Greetings,
>>>
>>> Mariano
>>>
>>>
>>>>
>>>> 2009/4/8 Mariano Martinez Peck <[hidden email]>:
>>>>>
>>>>>
>>>>> On Tue, Apr 7, 2009 at 9:21 PM, Andrey Larionov <[hidden email]
>>>>> >
>>>>> wrote:
>>>>>>
>>>>>> Two test in FontTest assumes what TextStyle>>default will answer a
>>>>>> some Accuny font with some size. But if we override default font -
>>>>>> test will fail. I'll try to find solution and fix, but new vm and
>>>>>> image crashed during debuging.
>>>>>> I think solution will be to create corresponding TextStyle for
>>>>>> test.
>>>>>>
>>>>>> Also i'm a newbie and can some clarify what is DefaultTextStyle? It
>>>>>> not declared as instance or class variable.
>>>>>
>>>>> I am also a but newbie but I think that's a symbol Is it actually
>>>>> #DefaultTextStyle ?
>>>>>
>>>>> If true, yes, it would probably be a symbol. A symbol, as Squeak By
>>>> Example
>>>>> says is:
>>>>>
>>>>> "
>>>>> Symbols are like Strings, in that they contain a sequence of
>>>>> characters.
>>>>>    However, unlike a string, a literal symbol is guaranteed to be
>>>> globally
>>>>>    unique. There is only one Symbol object #Hello but there may be
>>>>>    multiple String objects with the value 'Hello'.
>>>>> "
>>>>>
>>>>> See SBE for more documentation.
>>>>>
>>>>> However, if there is something that it is not a class neither a
>>>>> class
>>>>> variable, it can be a global variable. For example, do a expect it
>>>>> of
>>>>> Smalltalk. You may think Smalltalk is a class, but it doesn't. It is
>>>> global
>>>>> variable. Indeed it is an object of SystemDirectory.
>>>>>
>>>>> Cheers,
>>>>>
>>>>> Mariano
>>>>>
>>>>>>
>>>>>> _______________________________________________
>>>>>> Pharo-project mailing list
>>>>>> [hidden email]
>>>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Pharo-project mailing list
>>>>> [hidden email]
>>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>>
>>>>
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project