--- rxvt-unicode/doc/rxvt.1.pod 2005/02/16 21:49:36 1.58 +++ rxvt-unicode/doc/rxvt.1.pod 2005/02/17 15:07:48 1.59 @@ -370,11 +370,11 @@ Turn on/off secondary screen scroll (default enabled); resource B. -=item B<-keysym.>I: I +=item B<-keysym.>I I Remap a key symbol. See resource B. -=item B<-embed>: I +=item B<-embed> I Tells @@RXVT_NAME@@ to embed it's windows into an already-existing window, which enables applications to easily embed a terminal. @@ -392,6 +392,42 @@ terminal. This works regardless of wether the C<-embed> option was used or not. +Here is a short Gtk2-perl snippet that illustrates how this option can be +used (a longer example is in F): + + my $rxvt = new Gtk2::DrawingArea; + $...->add ($rxvt); # important to add it somewhere first + $rxvt->realize; # now it can be realized + my $xid = $rxvt->window->get_xid; + + system "@@RXVT_NAME@@ -embed $xid &"; + +=item B<-pty-fd> I + +Tells @@RXVT_NAME@@ NOT to execute any commands or create a new pty/tty +pair but instead use the given filehandle as the tty master. This is +useful if you want to drive @@RXVT_NAME@@ as a generic terminal emulator +without having to run a program within it. + +If this switch is given, @@RXVT_NAME@@ will not create any utmp/wtmp +entries and will not tinker with pty/tty permissions - you have to do that +yourself if you want that. + +Here is a example in perl that illustrates how this option can be used (a +longer example is in F): + + use IO::Pty; + use Fcntl; + + my $pty = new IO::Pty; + fcntl $pty, F_SETFD, 0; # clear close-on-exec + + system "@@RXVT_NAME@@ -pty-fd " . (fileno $pty) . "&"; + + # now communicate with rxvt + my $slave = $pty->slave; + while (<$slave>) { print $slave "got <$_>\n" } + =back =head1 RESOURCES (available also as long-options)