For Programmers: Free Programming Magazines  


Home > Archive > Tcl > August 2007 > Is it time for another Tcl/Tk book?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Is it time for another Tcl/Tk book?
Kuberan Naganathan

2007-08-26, 4:31 am

I for one think it's time that someone write a Tcl/Tk book covering the
latest developments in tcl/tk.

Anyone care to comment?

Areas of interest:
(Brent Welch doesn't really get into any of these...)

1. Latest features of tcl8.5
2. Object oriented tcl programming in incr Tcl or one of the other OO
extensions.
3. Tcllib coverage with programming examples.
4. Tcl development tools. (Open source and otherwise.)

5. Tcl tricks. (Like writng dynamic procs w/ stuff like set w $w etc...
This sort of stuff isn't obvious at all from the 11
syntactic rules of tcl...)

Who needs publishers? How about an e-book? (Perhaps a combination of open
source and for profit sections?)

Any thoughts?


Peter

2007-08-26, 4:31 am

"Kuberan Naganathan" <kuberan@att.net> wrote in message
news:46d0f746$0$24129$4c368faf@roadrunne
r.com...
>I for one think it's time that someone write a Tcl/Tk book covering the
>latest developments in tcl/tk.
> Anyone care to comment?


The help files that come with the Tcl distribution cover most
of the topics that you discuss.


Aric Bills

2007-08-26, 4:31 am

Dr. Ousterhout's classic, Tcl and the Tk Toolkit, is being updated to
cover Tcl/Tk 8.5. Google " Tcl/Tk Books updated for 8.5" for more
info. My guess is that it will cover #1 on your list really well, and
#5 to some extent.

You may also be interested in the "official" Tcl tutorial:
http://www.tcl.tk/man/tcl8.5/tutorial/tcltutorial.html

I think everyone would be in favor of high-quality, open-access
material covering any or all of the topics on your list.

Larry W. Virden

2007-08-26, 8:11 am

On Aug 25, 11:46 pm, "Kuberan Naganathan" <kube...@att.net> wrote:
> I for one think it's time that someone write a Tcl/Tk book covering the
> latest developments in tcl/tk.
>
> Anyone care to comment?
>
> Areas of interest:
> (Brent Welch doesn't really get into any of these...)
>
> 1. Latest features of tcl8.5


Well, the original Welch book, now augmented with info by Hobbes and
company, can't have gotten into this because it was released before
most of 8.5's features.

> 2. Object oriented tcl programming in incr Tcl or one of the other OO
> extensions.


The problem here is that no one agrees on what OO extension to use.
Trying to write something that is extension-agnostic seems like more
work than most people would be willing to go. There's still quite a
bit of confusion in my mind about the whole purpose of the core OO
work planned for Tcl 8.6, so I don't know if anything could be done
around that.

> 3. Tcllib coverage with programming examples.


This sounds like a whole book, by itself.

> 4. Tcl development tools. (Open source and otherwise.)


Perhaps this might be useful.

>
> 5. Tcl tricks. (Like writng dynamic procs w/ stuff like set w $w etc...
> This sort of stuff isn't obvious at all from the 11
> syntactic rules of tcl...)


Figuring out the specific tricks to write about would be the trick.

>
> Who needs publishers? How about an e-book? (Perhaps a combination of open
> source and for profit sections?)
>
> Any thoughts?


Do you really have to have a piece of tree in hand for all of this? Or
would some electronic form be as good?

Are you just wanting something to read, or would you like to write
some part of the above? What is needed are people willing to write -
the Tcl developers are trying to focus on getting Tcl 8.5, 8.6, and
9.0 out the door... there isn't a lot of time left to start writing
new books.

Michael Schlenker

2007-08-26, 8:11 am

Kuberan Naganathan schrieb:
> I for one think it's time that someone write a Tcl/Tk book covering the
> latest developments in tcl/tk.


> 3. Tcllib coverage with programming examples.

I tried a start for some of that for an older Tcllib version and in
german, but haven't found time to do much about it lately...

http://physnet.uni-oldenburg.de/~sc...cllib-intro.pdf

Currently i agree it would be a good time to do it, as Tcllib seems to
have not too many changes (new modules etc.), so a more formal document
than the man pages could last for a while.

Michael
Ron Fox

2007-08-26, 7:18 pm

Best of wiki.tcl.tk that would be sort of like the
Bentley book "Programming Pearls but collected from the
pages of wiki.tcl.tk. Only problem is who would select/edit
the work.

Ron.


Kuberan Naganathan wrote:
> I for one think it's time that someone write a Tcl/Tk book covering the
> latest developments in tcl/tk.
>
> Anyone care to comment?
>
> Areas of interest:
> (Brent Welch doesn't really get into any of these...)
>
> 1. Latest features of tcl8.5
> 2. Object oriented tcl programming in incr Tcl or one of the other OO
> extensions.
> 3. Tcllib coverage with programming examples.
> 4. Tcl development tools. (Open source and otherwise.)
>
> 5. Tcl tricks. (Like writng dynamic procs w/ stuff like set w $w etc...
> This sort of stuff isn't obvious at all from the 11
> syntactic rules of tcl...)
>
> Who needs publishers? How about an e-book? (Perhaps a combination of open
> source and for profit sections?)
>
> Any thoughts?
>
>

Donal K. Fellows

2007-08-26, 7:18 pm

Kuberan Naganathan wrote:
> 1. Latest features of tcl8.5


This is already in the works, and is mostly written. Once 8.5 goes to
beta, the authors will finalize the text and get it to the publisher.

> 2. Object oriented tcl programming in incr Tcl or one of the other OO
> extensions.


There is some coverage of this with an old version of [incr Tcl], but
there's not much newer that I'm aware of and I suspect that the time
isn't quite right yet for a shake-down in this area. Right now, doing a
work covering all the zOO of variants would be difficult.

> 3. Tcllib coverage with programming examples.


If you ask me, the problem here is that there's not a great deal of
commonality to the contents of tcllib. Perhaps a "Tcllib in a Nutshell"
or something like that. (If they can do Java, they can do tcllib...)

> 4. Tcl development tools. (Open source and otherwise.)


All I need is Emacs! There I said it... ;-)

> 5. Tcl tricks. (Like writng dynamic procs w/ stuff like set w $w etc...
> This sort of stuff isn't obvious at all from the 11 syntactic rules of tcl...)


Try starting at http://en.wikibooks.org/wiki/Tcl_Programming

> Who needs publishers? How about an e-book? (Perhaps a combination of open
> source and for profit sections?)


Depends on the author(s) and publisher(s). Really.

Donal.
Richard Owlett

2007-08-26, 7:18 pm

Peter wrote:
> "Kuberan Naganathan" <kuberan@att.net> wrote in message
> news:46d0f746$0$24129$4c368faf@roadrunne
r.com...
>
>
>
> The help files that come with the Tcl distribution cover most
> of the topics that you discuss.
>
>


The help files leave much to be desired!
They are written _by experts_ *FOR EXPERTS* :{

It has two weak points:
1. indexing
2. examples
a. lack of
b. pedagogically poor - tending towards complex, emphasizing power
rather than giving insight into ONE feature.
Donal K. Fellows

2007-08-26, 7:18 pm

Richard Owlett wrote:
> The help files leave much to be desired!
> They are written _by experts_ *FOR EXPERTS* :{
>
> It has two weak points:
> 1. indexing


The manual page format really doesn't support that sort of thing too
well. We do a fairly decent job of building a table-of-contents and
index automatically when converting to HTML, but the hard part of
building an index is really working out what keywords should be in
there. Suggestions are welcomed; email tcl-core@lists.sf.net (or me,
since it's likely it'll be me who actions it) if you want to help.

> 2. examples
> a. lack of


I've been working on fixing that in 8.5; we're reasonably complete in
the Tcl manpages, but we need more for Tk. The tricky bit is that the
example should be short and sweet, and it's a bit hard to do that nicely
in Tk. Oh, and the examples we've got do tend to illustrate basic usage
and, occasionally, interesting features.

A preview (accurate as of 8.5a5) is online at http://www.tcl.tk/man/tcl8.5

> b. pedagogically poor - tending towards complex, emphasizing power
> rather than giving insight into ONE feature.


The primary function of manual pages is to remind people who already
know the basics. The basics are there too, but are more than a bit
gnostically expressed. And the guide to writing code "in style" is not
part of the manual pages, mostly because it requires capabilities that
go a bit beyond the power of the manual page format.

Donal.
Michael Schlenker

2007-08-26, 7:18 pm

Richard Owlett schrieb:
> Peter wrote:
> The help files leave much to be desired!
> They are written _by experts_ *FOR EXPERTS* :{

Yes. The man pages try to be to the point and define what
a command does, which sometimes sounds a bit abstract.

A plus is that you have a good chance to understand a command
from reading the man pages (unlike php or in some parts Python),
where you might have lots of examples or quite some text, but
don't find the full info.
>
> It has two weak points:
> 1. indexing

In the ActiveState chm version you at least have full text search,
and indexing only really helps if you already know the keywords used
for indexing.
> 2. examples
> a. lack of

Most Tcl man pages should at least have some examples now, and usually
there is a wiki page with examples or more explantion for the others.
Tk still misses them, but there are the widget demos and things like that.

> b. pedagogically poor - tending towards complex, emphasizing power
> rather than giving insight into ONE feature.

That might be true. Its reference documentation, not introductory or
tutorial style material.

As always, patches and comments (e.g. documentation bugs or rfes)
are welcome. Examples and other stuff might better fit into the tutorial
than to bloat the man pages.

Michael
Richard Owlett

2007-08-26, 7:18 pm

Donal K. Fellows wrote:
> Richard Owlett wrote:
>
>
> The manual page format really doesn't support that sort of thing too
> well. We do a fairly decent job of building a table-of-contents and
> index automatically when converting to HTML, but the hard part of
> building an index is really working out what keywords should be in
> there. Suggestions are welcomed; email tcl-core@lists.sf.net (or me,
> since it's likely it'll be me who actions it) if you want to help.


Done. I've got time available (recovering from an accident) even if I
lack expertise.

Modifying ../ActiveTcl8.4.15.0.280619-html/index.html seems to be a
productive route. My starting premise is that all the needed descriptive
text already exists. It just needs to be made easily accessible to the
new user without throwing roadblocks at the expert user.

For my personal use I was going to make two modifications:
1. Add a second table in the structural format of "ActiveTcl 8.4.15.0
Documentation Index". The entries would be titles such as "Strings",
"File Handling", and other miscellaneous headings that described
things I had problems finding. The links would point further down the
page to entries under "Sitemap".
2. Have descriptive text for all headings in "Sitemap".
a. All major headings (e.g. BWidgets, Expect, IWidgets, Snack) would
get a description in "25 words or less". They would be comparable
to topic sentence of an introductory paragraph for that topic.
Hopefully I could lift the sentence direct from existing
documentation.
b. Subheadings would receive a short descriptive phrase of related
keywords as has already been done for "Tablelist" or "Tcl".

>
> I've been working on fixing that in 8.5; we're reasonably complete in
> the Tcl manpages, but we need more for Tk. The tricky bit is that the
> example should be short and sweet, and it's a bit hard to do that nicely
> in Tk. Oh, and the examples we've got do tend to illustrate basic usage
> and, occasionally, interesting features.


Good example creation is a special talent.


>
> A preview (accurate as of 8.5a5) is online at http://www.tcl.tk/man/tcl8.5


I don't like the format. *BUT* it has a significantly different goal
than ../ActiveTcl8.4.15.0.280619-html/index.html and is for a different
audience.

>
>
>
> The primary function of manual pages is to remind people who already
> know the basics. The basics are there too, but are more than a bit
> gnostically expressed. And the guide to writing code "in style" is not
> part of the manual pages, mostly because it requires capabilities that
> go a bit beyond the power of the manual page format.
>
> Donal.

Richard Owlett

2007-08-26, 7:18 pm

Michael Schlenker wrote:
> Richard Owlett schrieb:
>
>
> Yes. The man pages try to be to the point and define what
> a command does, which sometimes sounds a bit abstract.
>
>[LARGE SNIP]
>
> As always, patches and comments (e.g. documentation bugs or rfes)
> are welcome. Examples and other stuff might better fit into the tutorial
> than to bloat the man pages.
>
> Michael


My comment was directed at "Help system" not "man pages".
They are obviously closely related. But I see them as serving different
goals/audiences/???.
Keith Nash

2007-08-26, 10:12 pm

Richard Owlett wrote:

> For my personal use I was going to make two modifications:
> 1. Add a second table in the structural format of "ActiveTcl 8.4.15.0
> Documentation Index". The entries would be titles such as "Strings",
> "File Handling", and other miscellaneous headings that described
> things I had problems finding. The links would point further down the
> page to entries under "Sitemap".


This is a good idea. It is useful to group commands by their purpose,
rather than the extension that they belong to. A listing of all the string
handling commands would be particularly useful.

Keith.

suchenwi

2007-08-27, 4:38 am

On 26 Aug., 05:46, "Kuberan Naganathan" <kube...@att.net> wrote:
> Who needs publishers? How about an e-book? (Perhaps a combination of open
> source and for profit sections?)


How about http://en.wikibooks.org/wiki/Programming:Tcl ? It is all
"open-source", and as a Wikibook, open to improvement by anyone. Not
much 8.5-specific content so far, but everyone is welcome to improve
on that :^)

Twylite

2007-08-27, 4:38 am

On Aug 26, 5:46 am, "Kuberan Naganathan" <kube...@att.net> wrote:
> I for one think it's time that someone write a Tcl/Tk book covering the
> latest developments in tcl/tk.
>
> 1. Latest features of tcl8.5
> 2. Object oriented tcl programming in incr Tcl or one of the other OO
> extensions.
> 3. Tcllib coverage with programming examples.


6. Tile

IMHO the existing documentation on Tile is out of date, lacking and
confusing. I was going to write an intro with some examples, but
after studying the existing documentation, Tcl side of the source
code, and trying the (limited) introspection that appears to be
available in the interpreter, I couldn't work out how to do some
relatively simple things, e.g. Change the font the a TkTable, the
background the a button, etc.

One thing that me a lot is that each style seems to define
its own elements (not sure if that is the right thing to call them)
that make up UI widgets, there is no documentation on what these are,
and I couldn't find a way to introspect them. So you can define a
style that will change the colour of some part of a widget (e.g. the
background), but that won't necessarily work for another widget, or
for the same widget if you are using another style (like Mac instead
of XP).

My 2c,
Twylite



Larry W. Virden

2007-08-27, 11:25 am


>
> There is some coverage of this with an old version of [incr Tcl], but
> there's not much newer that I'm aware of and I suspect that the time
> isn't quite right yet for a shake-down in this area. Right now, doing a
> work covering all the zOO of variants would be difficult.
>


Chad Smith wrote an EXCELLENT book on OO programming using incr Tcl
(incr Tcl from the ground up). However, sales were weak, and the book
is now out of print (and someone "borrowed" my copy and never returned
it :-( ...)

Larry W. Virden

2007-08-27, 11:26 am

On Aug 26, 2:47 pm, Richard Owlett <rowl...@atlascomm.net> wrote:
> The help files leave much to be desired!
> They are written _by experts_ *FOR EXPERTS* :{
>
> It has two weak points:
> 1. indexing
> 2. examples
> a. lack of
> b. pedagogically poor - tending towards complex, emphasizing power
> rather than giving insight into ONE feature.



I hope that the community knows that one can submit feature requests
and bug reports against the documentation as well as examples or
source.

If you have specific changes to recommend, please submit them for
maintainers. I know I do this every version or two and the changes get
integrated in rather quickly.

Larry W. Virden

2007-08-27, 11:26 am

On Aug 26, 2:47 pm, Richard Owlett <rowl...@atlascomm.net> wrote:
> It has two weak points:
> 1. indexing
> 2. examples
> a. lack of
> b. pedagogically poor - tending towards complex, emphasizing power
> rather than giving insight into ONE feature.


As a part of the 8.5 effort, a Tcl tutorial is also being developed.
Please community members - read it, submit suggestions, new material,
etc. so that information meets the needs of the community.

Larry W. Virden

2007-08-27, 11:26 am

On Aug 26, 6:54 pm, Richard Owlett <rowl...@atlascomm.net> wrote:

[color=darkred]
> My comment was directed at "Help system" not "man pages".
> They are obviously closely related. But I see them as serving different
> goals/audiences/???.


To what help system do you refer? As far as I was aware, the only
reference material provided with Tcl (at least pre-8.5) are the man
pages.

Now, TclX had a help system. I always thought that moving that to Tcl
would have been a nice touch.

Richard Owlett

2007-08-27, 11:27 am

Larry W. Virden wrote:
> On Aug 26, 6:54 pm, Richard Owlett <rowl...@atlascomm.net> wrote:
>
>
>
>
>
>
> To what help system do you refer? As far as I was aware, the only
> reference material provided with Tcl (at least pre-8.5) are the man
> pages.
>
> Now, TclX had a help system. I always thought that moving that to Tcl
> would have been a nice touch.
>


Seems we are talking about slightly different things.

I downloaded a Windows(tm) version of Tcl/Tk from ActiveState's site
thus getting ActiveTcl. Included in that distribution is a "compiled
help system" ActiveTclHelp8.4.chm . They also offer a straight HTML
version available as ActiveTcl8.4.15.0.280619-html.tar.gz .

These files are apparently peculiar to and *copyright by* ActiveState.

The _content_ is apparently from the man pages. The organization and
presentation are ActiveState's.

Kuberan Naganathan

2007-08-28, 8:39 am

It would be nice to have a Tcl CookBook type reference also

I understand this is a lot of work. If everyone can contribute a few
examples...

The main problem with everyone contributing would be that the quality of the
content may vary somewhat.
A relative expert would need to arbitrate on the content.

A lot of what would go into the cookbook could be derived from postings on
CLT.

"The Best of comp.lang.tcl 2001-2007" or some such.

Our friend Perl's Cookbook can be used as a general guide. Tcl is just
plain better of course ;)



"Kuberan Naganathan" <kuberan@att.net> wrote in message
news:46d0f746$0$24129$4c368faf@roadrunne
r.com...
>I for one think it's time that someone write a Tcl/Tk book covering the
>latest developments in tcl/tk.
>
> Anyone care to comment?
>
> Areas of interest:
> (Brent Welch doesn't really get into any of these...)
>
> 1. Latest features of tcl8.5
> 2. Object oriented tcl programming in incr Tcl or one of the other OO
> extensions.
> 3. Tcllib coverage with programming examples.
> 4. Tcl development tools. (Open source and otherwise.)
>
> 5. Tcl tricks. (Like writng dynamic procs w/ stuff like set w $w etc...
> This sort of stuff isn't obvious at all from the 11
> syntactic rules of tcl...)
>
> Who needs publishers? How about an e-book? (Perhaps a combination of
> open source and for profit sections?)
>
> Any thoughts?
>
>



Rob

2007-08-28, 8:39 am

Kuberan Naganathan wrote:

> It would be nice to have a Tcl CookBook type reference also
>
> I understand this is a lot of work. If everyone can contribute a few
> examples...
>
> The main problem with everyone contributing would be that the quality of
> the content may vary somewhat.
> A relative expert would need to arbitrate on the content.
>
> A lot of what would go into the cookbook could be derived from postings on
> CLT.
>
> "The Best of comp.lang.tcl 2001-2007" or some such.
>
> Our friend Perl's Cookbook can be used as a general guide. Tcl is just
> plain better of course ;)
>


Not that it is a book, but have you looked at the ActiveState's "Tcl
Cookbook" at http://aspn.activestate.com/ASPN/Cookbook/Tcl

There's quite a bit of useful code there!

Rob.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com