yTin Homepage Logo
FastCounter by bCentral

  中文主页 | Home (english) | 快快下载 | 实战教程 | 命令帮助 | 实用工具 | 常问问题 | 讨论留言 | 友好泥潭 | 我的程序 | 全球镜像 |

yTin FAQ (under construction):

Compiling problems related to readline package.

u need find a copy of readline.tar.gz (e.g.,,
and untar it, then cd the readline source directory, ./configure, then make.
Warnings are OK to neglect, as far as you can get "libreadline.a" file.

You may want to save this "libreadline.a" file for future use, e.g.:
mkdir $HOME/bin
mv libreadline.a $HOME/bin

Then go back to ytin's source directory, do this:
./configure --libdir $HOME/bin

You may want to move the final "tt++" file to $HOME/bin and delete the readline
and yTin source files to save disk space.

Where can I get yTin binaries for my platform?

If you cannot compile yTin on your Unix machine because of readline or other issues, we have several binaries ready for you. Currently these binaries are from SourceForge's Compile Farm. Goto the yTin's project page at SourceForge and find the binary releases. Remember that since readline package is statically linked in these binaries to guarantee they will work on your machine, these files are about 2-3 times larger in size than those using dynamic readline libraries.
If you would like to contribute/maintain the binaries for other platforms (with readline static linked), please mail me so that I will add links to your homepage.
Here is how to get readline statically linked with yTin:
Get a copy of readline source code and compile, you will get two files: libreadline.a and libhistory.a. Put them in a directory, say, $HOME/lib.
Now enter the yTin's source directory, do:
./configure --libdir $HOME/lib
The tt++ file you get this way is about 2-3 times larger than normally you get and will work on others' machine of same platform (hopefully).

Why TinTin++ (for unix) does not display/input Chinese and some 8-bit bytes well?

This is caused by some options for GNU readline library.
In your home directory, check if there is already a file called ".inputrc" there.
Either edit it or create a new file named ".inputrc".
Add these lines to the file:

$if tintin++
set meta-flag On
set convert-meta Off
set output-meta On
#this is for use together with screen, C-a is screen's important key
#sacrifice C-l, coz redraw usually also defined as C-R
"\C-l": beginning-of-line
"\C-x\C-d": dump-macros

yTin's unix version turns these options (meta-flag, convert-meta and output-meta)
to correct values if "CHINESE" is defined during compile, which is current default.

How to use macros in yTin?

For Windows version, #help macro.
NEW from version 1.83!!! For unix version:
#macro {M-f} {flee}  <== Meta-f, case insensitive
#macro {PF3} {look;quit;scan} <== PF3 key

Keys other than Meta, PF1-4 are not implemented yet.
However, one can achieve some static effect by tweaking .inputrc file.
For example, in your .inputrc file (at $HOME directory):

$if tintin++
.... #some other settings, see the previous FAQ for details
#begin of macros
#these are for vt100 terminals
"\eOP": "F1\r"
"\eOQ": "F2\r"
"\eOR": "F3\r"
"\eOS": "F4\r"
"\eOt": "F5\r"
"\eOu": "F6\r"
"\eOv": "F7\r"
"\eOl": "F8\r"
"\eOw": "F9\r"
"\eOx": "F10\r"
"\eOy": "F11\r"
"\eOz": "F12\r"
#end of macros

After changed this .inputrc, restart tt++ or yTin, you can type:
CTRL-X CTRL-D to see that these macros are taking effect.

Here are some results for some popular terminal emulators:
with vt100 keys set in netterm, only
F1-F4 and F12 works fine. Others might have been eaten by readline
in some way. (Apparently you cannot re-map arrow keys, since
readline made use of them.)
F1-F12 in vt100 mode were mapped wrongly (e.g., F1-F4 were mapped
into arrow keys), but CRT let you to be able to re-map them.

One good feature is, though, when you press F1, it acts like you typed
the word "F1" then pressed RETURN, so you can change the alias F1 in
you .tintinrc file.
I believe if it is necessary, one can re-map the sequence generated by
F5-F11 so that these keys will work properly too.

CAUTION: These are results from my own experiments, by no way they are always
correct.  If you have anything to contribute, write to me or post at
yTin's discussion board.

How can I execute Perl script in yTin?

See helps on #system.
First you have to have perl installed, or at least have perl56.dll or similar installed for Windows. In View->Option menu, you can specify the path for perlXX.dll. Please use ActivePerl build 617 or later for Windows.
In brief:
#system perl
Advantage: accepts stdin and displays output to stdout
Limit: Cannot set actions on the output

#system perl
Limit: no stdin/stdout support at all currently. All I/O is
done in perl program by read/write files.
e.g.: You have write a line "Hello world!" into a file
called hello.txt. In yTin, you type:
#sys perl
#syscat hello.txt
Or you can write some commands in hello.txt, then use:
#textin hello.txt
#read hello.txt
(Compare the difference between #textin and #read commands.)

How can I have zMud like class feature in trigger/action?

For details why TinTin++'s priority feature is better than zMud's class implementation, please see helps on #action (the last paragraph).
Still, is it necessary for yTin to add this feature?
Short answer: NOT NECESSARY (unless I still get lots of demands on this after u read this FAQ.)
Solution 1:
#act {MESSAGE} {blah$class1}
#al blah0 {#nop}
#al blah1 {choice 1}
#al blah2 {choice 2}
Now, #var class1 0 == #t- class1 in zMud, #var class1 1 == #t+ class1 in zMud
Plus, you can do more than zMud could do with #t+ and #t-:
#var class1 2

Solution 2:
#act {MESSAGE} {#if {$class1} {blah1}}

Solution 3:
Want a syntax similar to zMud's such that you can use scripts (e.g. Perl)
to convert script file?
Let's create a help alias:
#al zHack {#al tmp {%1};#if {${%%%2}}{tmp}}
#act {MESSAGE} {zHack blah1 class1}
or, for safety (e.g., when blah1 contains space):
#act {MESSAGE} zHack {do this blah ...} {class1}
Now you can use #var class1 0, or #var class1 1 to replace #t+, #t-
Furthermore, you can still use priority:
#act {MESSAGE} {zHack {do this blah ...} {class1}} {1}

I had a habit, which might be helpful to avoid typos when write scripts:
#act {MESSAGE} {blah};#al blah0 {let's do this ...};#al blah blah0
Now, in your script, u can do:
#al blah #nop; to disable this action
#al blah blah0; to re-enable this action
This helps to prevent typo for MESSAGE.

ps: My friend "dawn" had a suggestion that I will implement later: Make priority be a variable instead, then when the variable is changed to -1, action is disabled. This will make yTin most "compatible" with zMud without losing the important priority feature.

Is it possible for yTin to remember its last window position?

From Fairlight: The one problem I've had is with it popping up offset on screen. It keeps creeping farther and farther over. The last time it was entirely off the desktop and invisible. Thankfully ALT-Space and M for move let me use the arrow keys to get it onto the desktop.
yTin will remember the windows position when closed if it is not maximized
nor minimized.
So what to do is: open only 1 window of yTin, change it to normal size, then
drag the edge of yTin to resize it to the position/size you want.  Even if
you want the maximized size, do it only by manually resize it. Now close yTin
once and yTin will remember this position.