Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

to use BLT or not

40 views
Skip to first unread message

Zhang Weiwu

unread,
Dec 18, 2010, 11:58:03 AM12/18/10
to
Hello. I am working on adding new feature to an old application. The new
feature would need to use two more widgets:

1. a hierarchical table (treeview) widget
2. an 2-layer ring-chart widget or a pie-chart widget.

The old application was designed to be compatible with tk 8.4. After
some research it turns out there are 2 options:

I either use ttk::treeview (of tk8.5) plus tkpiechart (of tcllib)

or I should use hiertable plus barchart, both belong to BLT.

It seems from minimum library dependency point of view, BLT is a better
choice.

But before I head to BLT I realized a second issue: BLT blocks tk8.5,
and it seems have not updated for many years. Both give a picture of an
abandoned project. I wouldn't go to a sinking ship, otherwise I would
have to update the application some years later, affecting the
application's life-cycle.

Since I am still new to the TCL world, how would you suggest? Would you
use BLT if you were me?

Roger Oberholtzer

unread,
Dec 20, 2010, 3:58:17 AM12/20/10
to

If it is a new project (it pains me to say this), don't use BLT. It is
perhaps not a dead project. But the sole developer has not released
code that functions with tcl 8.5+. It appears that he is doing
something along these lines. But as he does not provide a hint of
where he is headed, and when he plans to get there, it is difficult to
base anything on BLT. A package called RBC has tried to make Blt work
with the more recent Tcl setup. But that is not a complete Blt. Only
the charts. I am using that in legacy code.

The above is only my opinion.

Cyan

unread,
Dec 20, 2010, 7:53:57 AM12/20/10
to

I've weaned myself off using BLT (mostly because it lacks stubs
support, so deploying in a *kit is an issue)
That said I'm still addicted to the terse and readable syntax of the
blt::table geometry manager, so I hacked it out and tea'ed it, making
it only work against the public Tcl and Tk stubs tables. Tried to
contact the maintainer to ask about releasing it, but I didn't get a
reply.

Using ttk::treeview and tkpiechart seem like the cleaner route from a
dependency point of view, because they only depend on the core and
platform independent Tcl code.

Cyan

Larry W. Virden

unread,
Dec 20, 2010, 8:58:48 AM12/20/10
to
On Dec 18, 11:58 am, Zhang Weiwu <zhangwe...@realss.com> wrote:
>
> Since I am still new to the TCL world, how would you suggest? Would you
> use BLT if you were me?

The siren call of BLT is very hard to resist. I love all the
functionality in the package. However, in my specific case, I've been
unable to build a working version of BLT for six years on my platform.
Since you didn't mention the platform on which you are working, I
can't say for certain whether you will have the same issues as I have.

I just know that I've told my users that I am unable to provide BLT to
them for use in our production environment. Some of them have frozen
their code at ancient Tcl levels due to these issues.

I wish I could recommend a forked version of the code which had
support.

I also would recommend checking out the level of support for any
alternative package you might consider. Be certain that it is still
supported.

Tim Wallace

unread,
Dec 20, 2010, 9:13:03 AM12/20/10
to
If you are dealing with a lot of floating-point data, consider RBC which
includes the BLT vectors and graphs, which work very well together. We
use that with 8.5. For the other stuff, alternatives are available.
BLT is changing in unpredictable ways as well as not supporting recent
versions of tcl so I can't recommend that.

--Tim

Donal K. Fellows

unread,
Dec 20, 2010, 7:16:29 PM12/20/10
to
On Dec 20, 1:58 pm, "Larry W. Virden" <lvir...@gmail.com> wrote:
> I just know that I've told my users that I am unable to provide BLT to
> them for use in our production environment. Some of them have frozen
> their code at ancient Tcl levels due to these issues.

Which features of BLT are required/highly desirable for you? Tk 8.6
includes an extract of the BLT busy code, and I know I've seen an
extracted bgexec - though I forget where right now - so I'm
particularly interested in the other things that are in BLT's grab-
bag. After all, knowing which bits really matter is the key to doing
something about it.

Donal.

Uwe Klein

unread,
Dec 21, 2010, 4:13:36 AM12/21/10
to
Donal K. Fellows wrote:
> On Dec 20, 1:58 pm, "Larry W. Virden" <lvir...@gmail.com> wrote:
>
>>I just know that I've told my users that I am unable to provide BLT to
>>them for use in our production environment. Some of them have frozen
>>their code at ancient Tcl levels due to these issues.
>
>
> Which features of BLT are required/highly desirable for you?

table widget manager ( still the better grid imho )

vector, vector math

graph ( especially the use of vectors there )

never worked with the tree / treeview stuff but that abstraction
should have the same attraction the vector/graph combo has
bgexec ( writing into traceable variables, very nice )

uwe

Cyan

unread,
Dec 21, 2010, 8:14:35 AM12/21/10
to
On Dec 21, 2:16 am, "Donal K. Fellows"

table geometry manager - makes for compact, readable code:

blt::table . -padx 5 -pady 5 \
.editor 1,1 -fill both \
.vsb 1,2 -fill y \
.hsb 2,1 -fill x \
.buttons 3,1 -cspan 2 -pady {4 0}
blt::table configure . r2 r3 c2 -resize none

I find that much easier to glance at and mentally compile to a screen
layout than the equivalent grid syntax.

The only feature I really miss though is asymmetric padding support in
-pad and -ipad, makes tuning a layout much easier, without messing
with spacer rows and columns; and the 2 and 3 element variants of -
width and -height

Cyan

Uwe Klein

unread,
Dec 21, 2010, 8:34:18 AM12/21/10
to
Cyan wrote:
> The only feature I really miss though is asymmetric padding support in
> -pad and -ipad, makes tuning a layout much easier, without messing
> with spacer rows and columns; and the 2 and 3 element variants of -
> width and -height

being able to configure rowheight to zero.
I've used that to fold away a couple of lines

uwe

Zhang Weiwu

unread,
Dec 22, 2010, 11:30:57 AM12/22/10
to
Thanks a lot for all answers so far.

A conclusion is most would suggest against BLT for lack of development
and project planning.

A few replacement for BLT are recommended, like bgexec as in part of
tk8.6, RBC for BLT vectors and graphs.

Besides RBC there are some efforts from the WIZE project (wize.sf.net)
that adapted BLT for tk8.5. They have a so-called BLT 2.5 package
released on their project.

0 new messages