View · Search · Index
No registered users in community xowiki
in last 10 minutes

Weblog Page

Showing 1481 - 1490 of 1561 Postings (summary)

RE: [Xotcl] Interested in OO for tcl.

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Jeff Hobbs <jeffh_at_activestate.com>
Date: Mon, 4 Dec 2006 14:56:10 -0800

Artur Trzewik wrote:
> Jeff Hobbs schrieb:
> >> Many of XOTcl features are only interesting for special
> >> scenarios such as OO-frameworks or wrapping techniques.
> >>
> >> For OO-Beginners these XOTcl-Features might be not interesting:
> >> - method forwarding
> >> - filters
> >> - meta classes
> >> - slots
> >> - mixins
> >> - assertions, pre/post condition
> >> - non positional arguments
> >> - object aggregation
> >> I have ordered the features from most advenced to quite
> >> practical in my opionion.
> >
> > Method forwarding (aka delegation) is an absolute must and common
> > feature for megawidget development (fwiw).
> >
> Yes. But there is a difference between megawidget developer and
> developer who only use magawidget.
> For using megawideg you do need to now nothing about
> internals of it. Not everyone must be Tcl guru for using it.

It is true that there are always going to be more megawidget users than
authors, but don't underestimate the potential "developer base" of megawidget
authors. Look at how many systems and megawidgets others have developed. On
top of each of these (bwidgets, iwidgets, etc), developers have created their
own variations to solve problem need.

In fact, the only reason this hasn't been more commonplace is due in large
part to the lack of an accepted megawidget framework in Tk. I had hoped to
have one on top of the 8.5 OO, but that is deferred.

The need to customize minor variations of widgets is quite common for almost
any size of Tk app. Text widgets with readonly sections, entry widgets that
have special validation behaviors, comboboxes with hotlists and other fancy
features, ... Do not underestimate the importance of having *strong*
megawidget framework support in the core OO.

Jeff

Re: [Xotcl] NX attributes

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Victor Mayevski <vitick_at_gmail.com>
Date: Wed, 18 May 2011 11:01:41 -0700

Very good. Thanks.

On Wed, May 18, 2011 at 1:55 AM, Gustaf Neumann <neumann_at_wu-wien.ac.at> wrote:
> On 21.01.11 00:17, Victor Mayevski wrote:
>>
>> Although it might be something obvious but I cannot think of it at the
>> moment. How do I delete attributes created with the "attribute"
>> method?
>
> NX provides now an explicit "delete" ensemble, containing "delete method"
> and "delete attribute",
> therefore it does not require the classic Tcl metaphor "proc foo {} {}" for
> deleting a function foo.
> Furthermore, "delete attribute" removes the slot objects as well.
>
> So, one can use now
>
> /obj/  delete  attribute/name/
>
> -gustaf neumann
>

Re: [Xotcl] Non-pos arguments with args

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Gustaf Neumann <neumann_at_wu-wien.ac.at>
Date: Fri, 17 Feb 2006 18:53:07 +0100

Hi Kurt,

uff, this was mean: i did take me a while that the dashes from your
examples are not minus
signs, but different chars (hex e2 80 93; compare "-" with "-").

however, the bug occurs as well with the minus sign, so i expect these
dashes were
 introduced by your mail client.

below is a patch for xotcl-1.3.9, that will be included in the
forthcoming xotcl 1.4.0

-gustaf

=========================================================
--- generic/xotcl.c-orig 2005-12-09 10:43:19.000000000 +0100
+++ generic/xotcl.c 2006-02-17 18:44:20.000000000 +0100
_at__at_ -10437,7 +10437,12 @@
       ordinaryArgsCounter++;
     }
   }
- if (!argsDefined) {
+ if (argsDefined) {
+ if (ordinaryArgsCounter == 0) {
+ Tcl_SetVar2(in, "args", 0, "", 0);
+ }
+ } else {
+ /* !argsDefined */
     if (ordinaryArgsCounter != ordinaryArgsDefc) {
       /* we do not have enough arguments, maybe there are default arguments
         for the missing args */

=========================================================

Kurt Stoll schrieb:

>
>
> I am having difficulty getting non-positional arguments to behave
> correctly with args. The simple example below shows what I have
> found. This does not appear to be appropriate behavior. Am I doing
> something wrong?
>
>
>
> Object obj
>
> obj proc pr1 { {-npos default} args } {
>
> puts "npos: $npos"
>
> puts "args: $args"
>
> }
>
>
>
>> ## This works:
>
>> obj pr1 a
>
> npos: default
>
> args: a
>
>>
>
>> ## As does this:
>
>> obj pr1 -npos 3 a
>
> npos: 3
>
> args: a
>
>>
>
>> ## But this does not:
>
>> obj pr1 -npos 3
>
> npos: 3
>
> args: -npos 3
>
>>
>
>> ## I expected args to be {}, but instead it contains the
> non-positional parameter
>
>
>
> Thanks for any insight you can provide.
>
>
>
> -Kurt Stoll
>
>
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Xotcl mailing list
>Xotcl_at_alice.wu-wien.ac.at
>http://alice.wu-wien.ac.at/mailman/listinfo/xotcl
>
>

[Xotcl] [forwarded] XOTcl, threading and AOLserver ?

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Gustaf Neumann <Gustaf.Neumann_at_wu-wien.ac.at>
Date: Thu, 16 Nov 2000 18:52:55 +0100 (CET)


Hi !

First of all, I'm very excited about XOTcl ! I think
you did an excellent job.

Question 1: do you plan to make (XOTcl) MT-safe ?

Since Tcl8.2, Tcl core is MT-safe, and so should be
the extensions. I can help you out with this, if needed.
I've noticed couple of globals/statics which may have to be
either moved to thread-specific-data or mutex-protected.


Question 2: <read on>

Having nice introspection capabilities built into the
XOTcl, I wonder if one can write a Tcl script which
runs against the initialized interpreter and builds up
a script needed to re-construct all classes and/or object
which it finds there (in the interpreter)?

Why should one need this ?

Well, the AOLserver webserver which we use is a little bit
special. It sources initialization files in startup thread/interp
and then runs a series of scripts to get the interpreter
blue-print. This blue-print (in form of Tcl-code) is then
ran against each newly created interpreter. This is to
simplify and speed-up of new interpreter(s) initialization.
In order to use XOTcl in AOLserver, one should be able to
produce such a script programatically.
For plain Tcl code, this is no big deal. I think XOTcl would
not pose any problem, but nevertheless, it's better to ask.

Any comments ?

Cheer's
Zoran Vasiljevic


______________________________________________
FREE Personalized Email at Mail.com
Sign up at http://www.mail.com/?sr=signup

Re: [Xotcl] info not working?

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Gustaf Neumann <neumann_at_wu-wien.ac.at>
Date: Tue, 14 Sep 2004 15:26:58 +0200

On Thursday 02 September 2004 21:52, Kristoffer Lawson wrote:
> Yes, I found those things, but the documentation talks about methods.
> To me, methods mean everything. If it only means procs (not instprocs), I
> think it should be really clear about that.

 i made the documentation (tutorial and langref) more precise on this.
 Btw, "info instdefault" was missing in the tutorial, while "info default"
 was in there.

> I'm not even sure if it's a good idea that it only means object procs.

 since the obj procs and instprocs of various classes are allowed
 to have different signatures, it is required to query these separately.

 -gustaf

-- 
Univ.Prof. Dr.Gustaf Neumann
Abteilung für Wirtschaftsinformatik und Neue Medien
Wirtschaftsuniversität Wien, Augasse 2-6, 1090 Wien

[Xotcl] Re: [Xotcl] Re: [Xotcl] European Tcl meeting

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Kristoffer Lawson <setok_at_fishpool.com>
Date: Tue, 30 Jan 2001 15:19:06 +0200 (EET)

On Tue, 30 Jan 2001, Uwe Zdun wrote:

>
> we were discussing to submit something, but aren't sure about that yet.

Well even if it was just a "this is what we've done since last year"
thing, that would be great. Just to have some presence there, and to
meet the developers ;-)

> It
> would be great if someone else could also present something, as Kristoffer
> suggested.

If XOTcl itself had a presence it might be worthwhile sticking several
things together. Ie. have an intro to XOTcl and then let people
stand up to tell the crowd(?) what they're using XOTcl for. I definitely
volunteer to take part -- although the thing we're doing is quite large
so I could probably present it independently too, if we go along that
road.

         - ---------- = = ---------//--+
         | / Kristoffer Lawson | www.fishpool.fi|.com
         +-> | setok_at_fishpool.com | - - --+------
             |-- Fishpool Creations Ltd - / |
             +-------- = - - - = --------- /~setok/

[Xotcl] Around methods

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Ben Thomasson <ben.thomasson_at_gmail.com>
Date: Tue, 29 Apr 2008 13:19:12 -0400

Hi,

I was wondering if you had considered implementing before, after, and around
auxiliary methods similar to their implementation in CLOS? I understand
that similar things can be done with mixins and filters, but there are a few
things that are more easily done with auxiliary methods.

Thanks,

Ben

Auxiliary methods:
http://emacspeak.sourceforge.net/raman/publications/web-aster/root-thesisli13.html

Re: [Xotcl] configure hangs on sed -f command

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Gustaf Neumann <neumann_at_wu-wien.ac.at>
Date: Tue, 26 Aug 2003 18:43:38 +0200

Hi Cathrine,

 i have noticed a similar problem some months ago, when
 switching redhat versions. XOTcl uses the configure
 information from tcl. This file is found though configure,
 you will see a line like:

checking for Tcl configuration... found /home/neumann/tcl8.3.5/unix/tclConfig.sh

 check this file and see if you have _at_-variables in it and replace these
 variables with sensible values. i remember vaguely the details,
 but i had lines like

TCL_STUB_LIB_FILE='_at_TCL_STUB_LIB_FILE@'

 in it. This seems to cause the loop....
 
 hope this helps,
-gustaf


On Tuesday 26 August 2003 17:52, Catherine Letondal wrote:
> Hi,
>
> It's a long time I haven't re-installed Xotcl on my Sparc/Solaris and
> the unix directory configure apparently hangs on a part of the configure
> script where an sed -f command is executed:
>
> root 22332 99.6 0.7 984 776 pts/9 R 17:11:33 8:24 sed -f
> /tmp/cs2226...
>
> The /tmp/cs2226.../out file in this indeed empty.
>
> Could anybody help?
>
> Thanks in advance,

-- 
Univ.Prof. Dr.Gustaf Neumann
Abteilung für Wirtschaftsinformatik
WU-Wien, Augasse 2-6, 1090 Wien

Re: [Xotcl] Class naming and creation

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Zoran Vasiljevic <zv_at_archiware.com>
Date: Tue, 22 Nov 2005 15:18:44 +0100

On 22.11.2005, at 15:08, Gustaf Neumann wrote:

> Zoran, does this help? it will print
>
> ::xotcl::Class wants to create Foo
> ::Foo wants to create ::xotcl::__#1
> ::Foo wants to create bar
>
> You can do this also selectively for certain classes via mixins, or
> by defining
> an appropriate metaclass.

Ah, Gustaf, what would I do without you!?
This works perfectly! After all those years
of XOTcl'ing I should have come to that by
myself... But I'm now in great stress testing
our 2.0 release... so very short on time :-(

Thanks for the fast response. I will add this
into our code. The reason is: we have couple of
frequently used classes which take about 1 second
to load/create object (lots of internal stuff being
done) so I needed a simple re-use mechanism. Now
I can add simple caching of generated objects
per-thread which would speed-up certain operations
by factors of magnitude!

Cheers
Zoran

RE: [Xotcl] XoTCL 1.0 on AIX

Created by hypermail2xowiki importer, last modified by Stefan Sobernig 02 Jan 2017, at 11:15 PM

From: Jeff Hobbs <jeffh_at_ActiveState.com>
Date: Mon, 9 Dec 2002 16:44:51 -0800

> - the choice of ALLOCA is not good vor Visual C/C++ 5.0. Choosing MALLOC
> seems to be good and should be good for all IBM compilers

No, alloca != malloc. alloca uses stack and auto-frees. alloca should
also be available on AIX by including either -lc or -lbsd.

> - the compilers were formerly versioned with hex codes now they are with
> decimal codes which regrettably sabotages any scalar comparison so #if
> __IBMC__ >= 0x306 won't work. This makes it hard to distinguish between
> various IBM C compilers. If you insist compare only with = not with > or
<.

Ack, except for compiler bugs, what would want want to care about the
version of the compiler for?

> - the shared library configuration is not correctly used in the makefiles.
> see description below

It would probably help if someone upgraded this to TEA2 build system.
It isn't a big modification, but it does have notable improvements like
not requiring that the extension be built with the same compiler setup
as Tcl itself was. This is important on "odd" platforms like AIX, where
gcc and xlc/cc can greatly disagree.

  Jeff Hobbs The Tcl Guy
  Senior Developer http://www.ActiveState.com/
      Tcl Support and Productivity Solutions

Next Page