Ok, this is what I have:
ic=: 3!:4
endian=. a. i. {. 1 ic 1
(endian,0 0 0) { a.
(endian,1 0 0) { a.
(endian,2 0 0) { a.
(endian,3 0 0) { a.
I would like to see these binary forms explicitly in the J Session Manager.
I remember seeing them as such (some strange symbols but distinguishable).
I used J602 earlier. And am using J602 now. So, I my first guess was that
something is different in the windows gui controls on this laptop of mine.
I use this in the following ways:
RESPONSE=: (endian,3 0 0) { a.
a =. cmdr__o 'Mcmdcount__theObj' NB. this is a command send over a socket
and receives the data with a header that describes the data
I can then splice the message as follows:
splice a
+----+-+------+++
| |6|582396|||
+----+-+------+++
and compare the header as so
RESPONSE -: (> 0 { splice a)
1
Does this make my problem clear : I would like to see the various binary
forms distinguished in the J Session Manager. I am using Courier New font.
Is there any (OS) system setting that can help me here?
~Yuva
On Tue, Jun 24, 2008 at 5:43 PM, Chris Burke <[EMAIL PROTECTED]> wrote:
> It is not clear to me exactly what the problem is. What version of J was
> your previous system? What is your binary data? Anyway, the following
> may help - if not, please give us more details of what you want to do.
>
> The J6 session assumes that literal text (3!:0 is 2) is in utf8 format.
> If the text to be displayed is correct utf8, you should see the
> characters properly, as long as the font used supports each character.
> If the text is not correct utf8, you will see boxes (or other garbage
> characters). Note, earlier versions of J did not support utf8. Also, the
> point is "not utf8" rather than "not ascii".
>
> The script 'system\extras\config\colorsmp.ijs' is in utf8 format, and
> should be displayed correctly by the J6 session, and by any editor that
> can detect and display utf8. For some editors, you may need to
> explicitly set utf8 as the encoding.
>
> In general, binary data is not in utf8 format, and so will display as
> garbage. As Oleg suggests, you can use the hexdump facility to display
> binary data, with characters shown only where possible.
>
> Yuvaraj Athur Raghuvir wrote:
> > 1) Did you try opening j602\system\extras\config\colorsmp.ijs with
> notepad
> > and wordpad? Do you see the difference in the rendering of Line No 16? Is
> > this because notepad is unable to recognize unicode?
> >
> > 2) Unfortunately, I donot have access to my old machine anymore. So, what
> I
> > writing is from what I remember as having seen. All that you have said
> below
> > works as you described in my new machine.
> >
> > Ok, when I pass messages over the socket, I use binary translation for
> the
> > size of the message. In my previous machine, I was able to see some
> > representation of the data and was able to spot errors. Now, with these
> nice
> > small rectangles, I am clueless. Of course, I can always pretty print by
> > decoding. I was just hoping that there was a simpler way....
>
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm