YAPV (Yet Another Pickaxe Version)


(Gavin Kistner) #1

As promised in another thread, I am working on a new web version of the
Pickaxe book (“Programming Ruby - The Pragmatic Programmer’s Guide”).

Why?

  • This is a framed version, which (with JavaScript enabled) keeps the
    book chapters syncrhonized with the Wiki pages noting changes due to 1.8).

  • This version is valid HTML4 markup, with consistent semantic markup.
    (I kept the styles similar to the existing HTML versions, albeit
    slightly cleaner…however, a single different CSS file could be used to
    change the look near-completely.) [1]

  • Unlike all other versions based on the 0.4 release of the HTML/XML,
    this version has included in it some very important 25 missing pages
    from the section “The Ruby Language”! [2]

So, please check out the work so far [3] at:
http://phrogz.net/ProgrammingRuby/
and give me feedback. (It seems to work and look correct in Safari 1.2,
Mozilla 1.4, and IE6Win. Does it fail for you? Does something about the
display frustrate you?)

(-, /\ / / //

[1] When I started out, I was just going to frame the existing HTML.
Then I saw how broken it was. So I thought "Hey, I have the XML, it must
be clean…I’ll just throw a few regexp at it and voila! clean HTML."
Almost a week later, I’m a little over halfway done with all the pages. :expressionless:

[2] Dave kindly supplied me with some new XML, but only after I found an
HTML version of 0.3a on the web and started cleaning it. Sorry
Dave…I’ll look through the XML soon and clean up the changes as needed.

[3] Only the following sections are done: “Introduction”, “Facets of
Ruby”, “Ruby in Its Setting”, and "Ruby Crystallized"
I’m working on the Library Reference section now.


(Gavin Kistner) #2

Two things I forgot to add:

(1) I said I’m ‘done’ with most of the sections; that’s not quite true.
As a proud new owner of a physical copy of the book, I will be going
through and finding all the spots where it says "see yyy on page 219"
and adding hyperlinks to the appropriate section/table.

(2) If you work on the Wiki to make changes, it would be great (since
the chapters are so long) if you could add in headers with an ID for the
section you’re referring to. I’ve modified some of the Wiki pages
already, but for example:

If you have a comment about the aliasing section under “The Ruby
Language”, put in the Wiki page
http://www.rubygarden.org/ruby?ProgrammingRubyTwo/TheRubyLanguage
code like:

Aliasing

....my comment here...

Not only will this help make clear what you’re talking about, but the JS
that synchronizes the sections passes the hash for the section to the
Wiki when you click on that section in the TOC:
http://www.rubygarden.org/ruby?ProgrammingRubyTwo/TheRubyLanguage#aliasing
which will cause clicks on subsections in the TOC to synchronize the
bottom frame to the appropriate section, if one exists.

(Look at the url in the TOC to see what the id should be.)

···


(-, /\ / / //


(Mark J. Reed) #3

Gavin Kistner gavin@refinery.com writes:

  • This version is valid HTML4 markup, with consistent semantic markup.

Why HTML 4 rather than XHTML 1.1?

-Mark


(Zachary P. Landau) #4

So, please check out the work so far [3] at:
http://phrogz.net/ProgrammingRuby/
and give me feedback. (It seems to work and look correct in Safari 1.2,
Mozilla 1.4, and IE6Win. Does it fail for you? Does something about the
display frustrate you?)

It looks really nice, and is a good idea. Hopefully this will get people
to update the ProgrammingRubyTwo wiki more often, too. It’ll be much
easier to see where changes need to be made.

Thanks for setting this up.

···


Zachary P. Landau kapheine@hypa.net
GPG: gpg --recv-key 0x24E5AD99 | http://kapheine.hypa.net/kapheine.asc


(Charles Comstock) #5

Gavin Kistner wrote:

As promised in another thread, I am working on a new web version of the
Pickaxe book (“Programming Ruby - The Pragmatic Programmer’s Guide”).

Why?

  • This is a framed version, which (with JavaScript enabled) keeps the
    book chapters syncrhonized with the Wiki pages noting changes due to 1.8).

  • This version is valid HTML4 markup, with consistent semantic markup.
    (I kept the styles similar to the existing HTML versions, albeit
    slightly cleaner…however, a single different CSS file could be used to
    change the look near-completely.) [1]

  • Unlike all other versions based on the 0.4 release of the HTML/XML,
    this version has included in it some very important 25 missing pages
    from the section “The Ruby Language”! [2]

So, please check out the work so far [3] at:
http://phrogz.net/ProgrammingRuby/
and give me feedback. (It seems to work and look correct in Safari 1.2,
Mozilla 1.4, and IE6Win. Does it fail for you? Does something about the
display frustrate you?)

(-, /\ / / //

[1] When I started out, I was just going to frame the existing HTML.
Then I saw how broken it was. So I thought "Hey, I have the XML, it must
be clean…I’ll just throw a few regexp at it and voila! clean HTML."
Almost a week later, I’m a little over halfway done with all the pages. :expressionless:

[2] Dave kindly supplied me with some new XML, but only after I found an
HTML version of 0.3a on the web and started cleaning it. Sorry
Dave…I’ll look through the XML soon and clean up the changes as needed.

[3] Only the following sections are done: “Introduction”, “Facets of
Ruby”, “Ruby in Its Setting”, and "Ruby Crystallized"
I’m working on the Library Reference section now.

Looks really nice, unfortuneatly I can only get it to render in IE,
Mozilla Firebird seems to dislike it. I have javascript enabled, is
this is a bug?

Charles Comstock


(Paul William) #6

sooo slllooowwww.

···

On Fri, 2004-02-06 at 07:45, Gavin Kistner wrote:

As promised in another thread, I am working on a new web version of the
Pickaxe book (“Programming Ruby - The Pragmatic Programmer’s Guide”).

Why?

  • This is a framed version, which (with JavaScript enabled) keeps the
    book chapters syncrhonized with the Wiki pages noting changes due to 1.8).

  • This version is valid HTML4 markup, with consistent semantic markup.
    (I kept the styles similar to the existing HTML versions, albeit
    slightly cleaner…however, a single different CSS file could be used to
    change the look near-completely.) [1]

  • Unlike all other versions based on the 0.4 release of the HTML/XML,
    this version has included in it some very important 25 missing pages
    from the section “The Ruby Language”! [2]

So, please check out the work so far [3] at:
http://phrogz.net/ProgrammingRuby/
and give me feedback. (It seems to work and look correct in Safari 1.2,
Mozilla 1.4, and IE6Win. Does it fail for you? Does something about the
display frustrate you?)

(-, /\ / / //

[1] When I started out, I was just going to frame the existing HTML.
Then I saw how broken it was. So I thought "Hey, I have the XML, it must
be clean…I’ll just throw a few regexp at it and voila! clean HTML."
Almost a week later, I’m a little over halfway done with all the pages. :expressionless:

[2] Dave kindly supplied me with some new XML, but only after I found an
HTML version of 0.3a on the web and started cleaning it. Sorry
Dave…I’ll look through the XML soon and clean up the changes as needed.

[3] Only the following sections are done: “Introduction”, “Facets of
Ruby”, “Ruby in Its Setting”, and "Ruby Crystallized"
I’m working on the Library Reference section now.

.’’. Paul William : :' : Debian admin and user. '
`- Debian - when you have better things to do than fixing a system

debian.org


(Timon Christl) #7

Gavin Kistner wrote:

As promised in another thread, I am working on a new web version of the
Pickaxe book (“Programming Ruby - The Pragmatic Programmer’s Guide”).

Why?

  • This is a framed version, which (with JavaScript enabled) keeps the
    book chapters syncrhonized with the Wiki pages noting changes due to 1.8).

  • This version is valid HTML4 markup, with consistent semantic markup.
    (I kept the styles similar to the existing HTML versions, albeit
    slightly cleaner…however, a single different CSS file could be used to
    change the look near-completely.) [1]

  • Unlike all other versions based on the 0.4 release of the HTML/XML,
    this version has included in it some very important 25 missing pages
    from the section “The Ruby Language”! [2]

So, please check out the work so far [3] at:
http://phrogz.net/ProgrammingRuby/
and give me feedback. (It seems to work and look correct in Safari 1.2,
Mozilla 1.4, and IE6Win. Does it fail for you? Does something about the
display frustrate you?)

Works well with Moz 1.6, but the left frame seems to load very slowly.

One things buggers me, though: There are no figures in the text as
opposed to the real, printed thing. Just “figure x.yy not available”.
This was already the case in the online copy of the pickaxe book for
Ruby 1.6.7. This is annoying because some important details are
contained within the figures, such as the Exception class hierarchy
(figure 8.1), or some pieces of code in the “extending Ruby” chapter.

It would be really nice if the figures could be added to your work.
Thanks in advance.

···


(defun f(p x)(If(Eq x nil)nil(If(p(Car x))(Cons(Car x)(f p(Cdr x)))(f p
(Cdr x)))))(defun q(x)(Q nil x))(defun Q(a x)(If(Eq x nil)a(Q(Cons(Car
x)(Q a(f(Lt(Car x))(Cdr x))))(f(Gt(Car x))(Cdr x)))))


(Gavin Kistner) #8

Mark J. Reed wrote:

Why HTML 4 rather than XHTML 1.1?

For various reasons. The two main ones are that
(a) XHTML doesn’t get you anything over HTML, except perhaps the ability
to apply XSLT to it. It’s no more semantic.

(b) Web Browsers are HTML UAs, not XHTML UAs. Some happen to know how to
pretend that XHTML is HTML when served properly, but that’s not the same
thing at all. (For more on this topic, see an excerpt from the MacIE
mailing list from the illustrious Tantek Çelic at:
http://phrogz.net/tmp/TantekOnXHTML.txt )

I sense that my comments are likely to spark a heated debate, which
would be inappropriate for this newsgroup. Please send rants on why
XHTML will save the Universe to me personally, rather than to the newsgroup.

···


(-, /\ / / //


(Gavin Kistner) #9

Charles Comstock wrote:

Looks really nice, unfortuneatly I can only get it to render in IE,
Mozilla Firebird seems to dislike it. I have javascript enabled, is
this is a bug?

It may have been at the time. It now should be rendering perfectly in
Mozilla and Safari, and ‘well-enough’ in IE.


(Gavin Kistner) #10

Timon Christl wrote:

Works well with Moz 1.6, but the left frame seems to load very slowly.

See my previous post in response to Paul William.

One things buggers me, though: There are no figures in the text as
opposed to the real, printed thing. Just “figure x.yy not available”.
This was already the case in the online copy of the pickaxe book for
Ruby 1.6.7. This is annoying because some important details are
contained within the figures, such as the Exception class hierarchy
(figure 8.1), or some pieces of code in the “extending Ruby” chapter.

If I had any legal way to do these, I would. But I don’t have access to
anything more than the XML everyone else uses, which doesn’t include any
figures. :confused:


(Gavin Kistner) #11

Paul William wrote:

sooo slllooowwww.

Glad you like it :slight_smile:

Seriously, are you referring to the site’s transmission speed (which
should be relatively speedy) or the loading of the 60k TOC frame?

If the latter:

(a) It has now been set to cache by the server, and

(b) If you’re using IEWin and have it set to check for newer versions of
files “Every Time” it will hit the server for each image in the nav.
Every time. Nearly 1,000 image instances. Regardless of the fact that
the server is sending HTTP caching headers.

Tip: change the setting back to “Automatically” :slight_smile:


(Charles Comstock) #12

Gavin Kistner wrote:

Charles Comstock wrote:

Looks really nice, unfortuneatly I can only get it to render in IE,
Mozilla Firebird seems to dislike it. I have javascript enabled, is
this is a bug?

It may have been at the time. It now should be rendering perfectly in
Mozilla and Safari, and ‘well-enough’ in IE.

I’m running mozilla firebird .7, and it still has trouble. I shoudln’t
have said it wouldn’t render actually, but when you click on the link it
says “ERROR! Cannot find object for Sync” in a javascript error. It
links fine in IE, but firebird doesn’t seem to like it. I plan on
updating to .8 soon, so that might fix it, but .7 shouldn’t have any
particular problem with javascript.

Charles Comstock


(Harpo) #13

It also renders well in Opera.

It’s a good improvement of the book, I changed my bookmark to point to
your site.

···

On Tue, 10 Feb 2004 22:43:36 +0000, Gavin Kistner wrote:

It may have been at the time. It now should be rendering perfectly in
Mozilla and Safari, and ‘well-enough’ in IE.


(Paul Brannan) #14

I’m using Mozilla and the loading of the TOC frame does take about 10
seconds on my P3/850. Once it’s loaded, navigation is quick, so I don’t
think this is a problem.

One minor nit: the background isn’t set in the main frame, so on my
browser it comes out grey. This would be fine if the TOC frame were
also using the default background color, but as it is I get one frame
white and one frame grey.

Paul

···

On Wed, Feb 11, 2004 at 07:49:58AM +0900, Gavin Kistner wrote:

Seriously, are you referring to the site’s transmission speed (which
should be relatively speedy) or the loading of the 60k TOC frame?


(Harpo) #15

Well … I spoke too quick, It does not render so well.
There is something which looks like a little problem in Opera.

It happens in the examples given when you document the methods of a class,
let’s take an example for short :

In module kernel

//
Array

Array( arg ) -> anArray

Returns arg.to_a.

Array(1…5)
-> [1, 2, 3, 4, 5]
//

The line “Array( arg ) -> anArray” appears very fine.

“-> [1, 2, 3, 4, 5]” in on the line below “Array(1…5)”, behaviour which
is probably not expected.

It is not always important, especially when there is only one line in the
example, when there are 2 lines or more, they may be overprinted (I don’t
know if it is the good english term but 2 characters are displayed at the
same place, mixed, thus difficultly understandable) !

I have a minimalistic knowledge of html, it may be (probably it is) a
problem in Opera. I can’t even make a good cute&paste to show you this
disaster :slight_smile:

If you ever wish to get rid of this problem and you don’t have an Opera
working by your side, you can send me emails for further informations or
tests.

My true email address is ji_gme.pe_mawanadoo.fr
… not exactly, you’ll have to remove underscores and the dot and change
"" to "@"
thus aa_bb.cc_ddwhatever gives aabbccdd@whatever (which I hope not to
be a real email adddress !)
You might say I’m paranoid but I usually use rot13 too !

···

On Wed, 11 Feb 2004 09:10:06 +0100, Harpo wrote:

On Tue, 10 Feb 2004 22:43:36 +0000, Gavin Kistner wrote:

It may have been at the time. It now should be rendering perfectly in
Mozilla and Safari, and ‘well-enough’ in IE.

It also renders well in Opera.


(Dennis Ranke) #16

IE shows the same behaviour when the frame doesn’t have enough horizontal
space to display the whole line. Firebird instead choses to push the right
side over the left one, which is slightly better at mose times.

This whole problem is more appearant in Opera, because Opera appears to
wrap to the next line much earlier than IE, ie. tries to keep a larger
margin to the right side of the box.

···

On Wed, 11 Feb 2004 14:24:13 +0100, Harpo harpo@nexs.fr wrote:

Well … I spoke too quick, It does not render so well.
There is something which looks like a little problem in Opera.

It happens in the examples given when you document the methods of a
class,
let’s take an example for short :

In module kernel

//
Array

Array( arg ) -> anArray

Returns arg.to_a.

Array(1…5)
-> [1, 2, 3, 4, 5]
//

The line “Array( arg ) -> anArray” appears very fine.

“-> [1, 2, 3, 4, 5]” in on the line below “Array(1…5)”, behaviour which
is probably not expected.


exoticorn/farbrausch


(Gavin Kistner) #17

Paul Brannan wrote:

One minor nit: the background isn’t set in the main frame, so on my
browser it comes out grey. This would be fine if the TOC frame were
also using the default background color, but as it is I get one frame
white and one frame grey.

Thanks. Fixed.