Re: [Clip] Go To Physical Line, Structured Programming, Tutorials
- On Sunday 05 November 2006 13:57, Veli-Pekka Tätilä wrote:
> Alan_C wrote:<snip>
> <snip> AreNot at the notetab site. But it's at the yahoo groups web site.
> all of the archived clips available via the note tab dot com site?
(I Google for: yahoo groups) turns up a few links of which the next is one of
start there. log in with your yahoo groups username and password then your
groups will be shown. click on ntb-clips and then can use their search. Yes
AFAIK all can be searched at this site.
At Google can search the yahoo groups domain (hits more than 1 notetab mailing
list archive though) thus:
> would be great if the most popular and or heavily requested clips could beyahoo groups www files area. And also,
> bundled with NoteTab.
> Are there any ways of adding clip commands to menus? I'd like to put myIt's already on the menu (of version 5 Notetab Pro)
> alternative go to line command in the search or NoteTab context menu.
search > go to line
alternate: Shift + Ctrl + L
That brings up a dialog where you then enter the line number that you want to
> SUreThe above is keyboard integrated. Does it work for you?
> you can use the in-context clip book, for example, but it doesn't feel as
> integrated as the native NoteTab commands. TOolbars are fairly visual, as
> well, and cannot receive the keyboard focus without screen reader specific
> And you can think of the do_while_ prefix as a poor man's namespace. AreI do not know. I've seen some that (to me) appear long and work. But how
> there length restrictions about labels?
long can go with them, I don't know.
Notetab is an editor that is programmable. To write a clip is to write a
macro. It's a macro language, albeit a powerful one.
> are there any good clip tutorials? I've taken a look atI don't know where to refer you to here. cliptut written by Jody Adair is
> one clip tut but would prefer something that resembles a crash course for
> programmers. The official docs, that are mostly a reference, are a bit too
> reference like yet not formal enough.
good. But I think it leans more towards non programmers. Perhaps search and
peruse the clips at yahoo groups web site? There's also another emailing
It's now rather inactive but would good to join it so can then search it at
the yahoo groups as I explained up above.
> I'm a big fan of the style found in<snip>
> Are there any "conversion" examples that show why I should use Clips inI'm like you. I just use whatever I want. Perl integrates well with Notetab.
> stead of language X for text processing?
If you haven't already and want to use Perl in Notetab then I'd highly
recommend you search both ntb-clips and ntb-scripts groups at yahoo groups
for relevant search terms. It's not all that difficult to use Perl (or
Python) from within Notetab.
> I know I should put more effort<snip>
> into learning clip but it's rather low in my priority queue of things to
(just a guess) I'd guess you could mostly Perl from within Notetab and,
outside of this, learn the remainder of the clip language at your leisure.
> >> 2. Can variables be localized to a label or blockWell, I got corrected some on this :-) I only meant that in a general way and
> > No. All are global.
yes there are variances from that and yes you can clearvariable -- and
What I meant by that is "global in the sense that from within the clip where a
certain specified variable exists" which would be very near to what Perl
calls "file scope".
But, forgive me for I was too general and I did not add on enough specifics
onto my generality. And, disclaimer, I may still not have tagged on enough
specifics onto my this/these generality(s).
Once again, it is a macro language. Many things you accustomed to from using
programming languages, you will not find (at least not *directly* find)
direct equivalents to them in this language.
> it is almost like if you had to tell C when you ment the colon in a caseOnce again, a macro language. In some cases there will be no direct
> label and when it is the question colon operator for flow control. Coming
> from Perl, I've gotten used to the parser being smart and guessing right in
> ambiguous situations.
equivalents to what's in a programming language.
> Which reminds me, one of the things in clips that has tripped me up is notYou could put in a feature request.
> requiring that variables be declared explicitly. So if one says something
> ^!Set %VariableName%=Data
> And then:
> ^!Prompt ^%ariableName%
> The language actually thinks you want to introduce a new variable even
> though it is an actual parameter for a function and not being assigned to.
> And in general thanks for the post. YOu've clarified a number of thingsAn ini file is not needed for persistence. (to persist across sessions).
> that the clip manual doesn't state in programmer jargon. It never says
> variables are global unless you make them persistant by writing them down
> in ini files and so on.
An ini can hold the values seperate from the clip. And another, ini
facilitates the ease to change a value(s) from one session to the next (write
a different value to the ini file).
There may be even more that an ini can do.
But a variable inside a clip comes back each time that clip is launched which
means that this variable persists across sessions. (mostly so or in general,
but also see my disclaimer above)
<snip about typing and clip syntax>
It's a macro language. Take it for what it is.
It's a language with which to "program" the editor. But it is not
a "programming" language.