unimportant sanity \xa0

View: New views
6 Messages — Rating Filter:   Alert me  

unimportant sanity \xa0

by adaml2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Some files contains \xa0, often with combination \x0a\xa0.
Probably they were generated by script with typo.
It fired exception in my script !!! So I tell you, really don't do that.


"./doc/timers.html"  .. [123, 10, 160, 32, 70]
"MAP(MyObject) MyObjectMap[]={\n� FXMAPFUNC(SEL_IO_READ,MyObje"                          

"./doc/install.html"  .. [46, 32, 160, 10, 10]
"ed to detect QNX\nare present. �\n\nAlso, for now it is probabl"                        

"./doc/projects.html"  .. [100, 32, 160, 111, 102]
"n water, coastal defenses and �offshore\nservices. Boskalis h"                            

"./doc/news1.html"  .. [46, 32, 160, 67, 111]
", etc.</li>\n  <li>FXFileDict. �Compile-time option to enable"                            

"./doc/menu.css"  .. [10, 125, 160, 160, 160]        
"00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"                      

"./doc/styles.css"  .. [10, 125, 160, 160, 160]      
"00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"                      

ada

P.S. And I'm just curious.  metaClass->assocsz == 16 for all cases.




------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: unimportant sanity \xa0

by mirv-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Looks like your script doesn't handle unicode. Also, the indicated files don't contain those characters for me. Which version of fox are you using?

  mirv
the Silly Fish.


On Sun, Aug 23, 2009 at 8:17 PM, <adaml2@...> wrote:

Some files contains \xa0, often with combination \x0a\xa0.
Probably they were generated by script with typo.
It fired exception in my script !!! So I tell you, really don't do that.


"./doc/timers.html"  .. [123, 10, 160, 32, 70]
"MAP(MyObject) MyObjectMap[]={\n� FXMAPFUNC(SEL_IO_READ,MyObje"

"./doc/install.html"  .. [46, 32, 160, 10, 10]
"ed to detect QNX\nare present. �\n\nAlso, for now it is probabl"

"./doc/projects.html"  .. [100, 32, 160, 111, 102]
"n water, coastal defenses and �offshore\nservices. Boskalis h"

"./doc/news1.html"  .. [46, 32, 160, 67, 111]
", etc.</li>\n  <li>FXFileDict. �Compile-time option to enable"

"./doc/menu.css"  .. [10, 125, 160, 160, 160]
"00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"

"./doc/styles.css"  .. [10, 125, 160, 160, 160]
"00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"

ada

P.S. And I'm just curious.  metaClass->assocsz == 16 for all cases.




------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: unimportant sanity \xa0

by adaml2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


> ------------ Původní zpráva ------------
> Od: mirv <mirviv@...>
> Předmět: Re: [Foxgui-users] unimportant sanity \xa0
> Datum: 23.8.2009 22:14:04
> ----------------------------------------
> Looks like your script doesn't handle unicode. Also, the indicated files
You got me. I corrected my script, when it fired errors - but also did the investigation...
I like that many bugs are found as a side effect of other bug.

> don't contain those characters for me. Which version of fox are you using?
snapshot 1.7.*
>
>   mirv
> the Silly Fish.

You can try this. But 'ruby -v' better be 1.9.1. Older 1.8.x will not.

#!/usr/bin/env ruby
require 'find'

Find.find('.') { |fp|
        Find.prune if File.basename(fp) =~ /\A\.git|\.libs$/
        next if File.directory?(fp) or fp.strip =~ /\.(?:jpeg|jpg|png|gif|bmp|o|lo)$/
        s = File.read(fp)             # it read file and assigns UTF-8 encoding as a default - no conversion ! just property assignment
        next if s.valid_encoding?
        p fp
}

Jeroen looks as using ISO8859-1, so there are other files ( AUTHORS, fox.spec.in ).
But I don't push everything into unicode - yeah, it would be better if you ask me.
Only thing, that "\xa0" is an unintended typo. That's all.

ada

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: unimportant sanity \xa0

by Jeroen van der Zijp :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Sunday 23 August 2009, adaml2@... wrote:

>
> Some files contains \xa0, often with combination \x0a\xa0.
> Probably they were generated by script with typo.
> It fired exception in my script !!! So I tell you, really don't do that.
>
>
> "./doc/timers.html"  .. [123, 10, 160, 32, 70]
> "MAP(MyObject) MyObjectMap[]={\n� FXMAPFUNC(SEL_IO_READ,MyObje"                          
>
> "./doc/install.html"  .. [46, 32, 160, 10, 10]
> "ed to detect QNX\nare present. �\n\nAlso, for now it is probabl"                        
>
> "./doc/projects.html"  .. [100, 32, 160, 111, 102]
> "n water, coastal defenses and �offshore\nservices. Boskalis h"                            
>
> "./doc/news1.html"  .. [46, 32, 160, 67, 111]
> ", etc.</li>\n  <li>FXFileDict. �Compile-time option to enable"                            
>
> "./doc/menu.css"  .. [10, 125, 160, 160, 160]        
> "00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"                      
>
> "./doc/styles.css"  .. [10, 125, 160, 160, 160]      
> "00;\nheight:1px;\n\nwidth:100%;\n}������� �������\n\n.SEPVER\n{\ncol"                      

It appears these are "no-break" spaces.  I'll try get rid of these; thanks
for pointing that out.

> P.S. And I'm just curious.  metaClass->assocsz == 16 for all cases.

Yes, well, OFFICIALLY, we don't know what your compiler's pointer-to-member
representation is.  On some compilers, pointer-to-member may always be the same
size, on others it may depend on multiple-inheritance being used or not (etc).  

So, just to be safe, the actual compiler-generated value is recorded into the
metaclass, so we can skip that amount in memory and be assured to have the
proper offset.


        - Jeroen

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: unimportant sanity \xa0

by Jeroen van der Zijp :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Sunday 23 August 2009, mirv wrote:
> Looks like your script doesn't handle unicode. Also, the indicated files
> don't contain those characters for me. Which version of fox are you using?

No, 0xA0 is no-break space.  Its NOT UTF-8, because in UTF-8 this would be encoded
as two bytes (C2 A0).


        - Jeroen

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: unimportant sanity \xa0

by mirv-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Ah, thanks for clearing that one up for me!

  mirv
the Silly Fish.


On Mon, Aug 24, 2009 at 4:40 PM, Jeroen van der Zijp <jeroen@...> wrote:
On Sunday 23 August 2009, mirv wrote:
> Looks like your script doesn't handle unicode. Also, the indicated files
> don't contain those characters for me. Which version of fox are you using?

No, 0xA0 is no-break space.  Its NOT UTF-8, because in UTF-8 this would be encoded
as two bytes (C2 A0).


       - Jeroen

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users