⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 os_beos.txt

📁 MSYS在windows下模拟了一个类unix的终端
💻 TXT
字号:
*os_beos.txt*	For Vim version 5.8.  Last change: 2001 May 09		  VIM REFERENCE MANUAL    by Bram Moolenaar							*BeOS* *BeBox*This is a port of Vim 5.1 to the BeOS Preview Release 2 (also known as PR2)or later.This file contains the particularities for the BeBox/BeOS version of Vim.  Formatters not discussed in this file, Vim behaves very much like the Unix|os_unix.txt| version. 1. General			|beos-general| 2. Compiling Vim		|beos-compiling| 3. Timeout in the Terminal	|beos-timeout| 4. Unicode vs. Latin-1		|beos-unicode| 5. The BeOS GUI		|beos-gui| 6. The $VIM directory		|beos-vimdir| 7. Drag & Drop			|beos-dragndrop| 8. Single Launch vs. Multiple    Launch			|beos-launch| 9. Fonts			|beos-fonts|10. The meta key modifier	|beos-meta|11. Mouse key mappings		|beos-mouse|12. Color names			|beos-colors|13. Compiling with Perl		|beos-perl|14. WARNING: Intel    "architecture" detected!	|beos-ppc|							*beos-general*The default syntax highlighting mostly works with different foreground colorsto highlight items. This works best if you set your Terminal window to adarkish background and light letters. Some middle-grey background (forinstance (r,g,b)=(168,168,168)) with black letters also works nicely.  If youuse the default light background and dark letters, it may look better tosimply reverse the notion of foreground and background color settings. To dothis, add this to your .vimrc file (where <Esc> may need to be replaced withthe escape character):>  if &term == "beos-ansi">      set t_AB=<Esc>[3%dm>      set t_AF=<Esc>[4%dm>  endifCompiling Vim						*beos-compiling*From the Advanced Access Preview Release (AAPR) on, Vim can be configured withthe standard configure script. To get the compiler and its flags right, usethe following command-line in the shell (you can cut and paste it in one go):CC=$BE_C_COMPILER CFLAGS="$BE_DEFAULT_C_FLAGS -O7" \    ./configure --prefix=/boot/home/config \    --disable-perlinterp --disable-pythoninterp$BE_C_COMPILER is usually "mwcc", $BE_DEFAULT_C_FLAGS is usually "-I- -I."When configure has run, and you wish to enable GUI support, you must edit theconfig.mk file so that the lines with GUI_xxx refer to $(BEOSGUI_xxx) insteadof $(NONE_xxx).Alternatively you can make this change in the Makefile; it will have amore permanent effect. Search for "NONE_".After compilation you need to add the resources to the binary. Add thefollowing few lines near the end (before the line with "exit $exit_value") ofthe link.sh script to do this automatically.    rmattr BEOS:TYPE vim    copyres os_beos.rsrc vim    mimeset vimAlso, create a dummy file "strip":    #!/bin/sh    mimeset $1    exit 0You will need it when using "make install" to install Vim.Now type "make" to compile Vim, then "make install" to install it.If you want to install Vim by hand, you must copy Vim to $HOME/config/bin, andcreate a bunch of symlinks to it ({g,r,rg}{vim,ex,view}). Furthermore you mustcopy Vims configuration files to $HOME/config/share/vim:vim-5.0s/{*.vim,doc,syntax}.  For completeness, you should also copy the nroffmanual pages to $HOME/config/man/man1. Don't forget xxd/xxd!Obviously, you need the unlimited linker to actually link Vim. Seehttp://www.metrowerks.com for purchasing the CodeWarrior compiler for BeOS.There are currently no other linkers that can do the job.This won't be able to include the Perl or Python interfaces even ifyou have the appropriate files installed. |beos-perl|Timeout in the Terminal					*beos-timeout*Because some POSIX/UNIX features are still missing[1], there is no direct OSsupport for read-with-timeout in the Terminal. This would meat that you cannotuse :mappings of more than one character, unless you also :set notimeout.|'timeout'|To circumvent this problem, I added a workaround to provide the necessaryinput with timeout by using an extra thread which reads ahead one character.As a side effect, it also makes Vim recognize when the Terminal windowresizes.Function keys are not supported in the Terminal since they produce veryindistinctive character sequences.These problems do not exist in the GUI.[1]: there is no select() on file descriptors; also the termios VMIN and VTIMEsettings do not seem to work properly. This has been the case since DR7 atleast and still has not been fixed as of PR2.							*beos-unicode*Unicode vs. Latin-1					*beos-utf8*BeOS uses Unicode and UTF-8 for text strings (16-bit characters encoded to8-bit characters). Vim assumes ISO-Latin-1 or other 8-bit character codes.This does not produce the desired results for non-ASCII characters. Try thecommand :digraphs to see. If they look messed up, use :set isprint=@ to(slightly) improve the display of ISO-Latin-1 characters 128-255.  This worksbetter in the GUI, depending on which font you use (below).You may also use the /boot/bin/xtou command to convert UTF-8 files from (xtou-f iso1 filename) or to (xtou -t iso1 filename) ISO-Latin-1 characters.Some remarks about the GUI:				*beos-gui*Normally Vim starts with the GUI if you start it as gvim or vim -g.  The BeOSversion tries to determine if it was started from the Tracker instead of theTerminal, and if so, use the GUI anyway. However, the current detection schemeis fooled if you use the command "vim - </dev/null" or "vim filename &". Thelatter can be called a feature but probably only works because there is noBSD-style job control.Stuff that does not work yet:- Running external commands from the GUI does not work 100% (again due to lack  of support for select()). There was a choice between seeing the command's  output, or being able to interrupt it. I chose for seeing the output. Even  now the command sometimes crashes mysteriously, apparently in Be's  malloc_internal() called from the putenv() function, after fork()ing. (data  access exception occurred, ec01b0ec:  90e80000 *stw r7, 0x0000 (r8))(:!ls  works usually, :r !ls usually doesn't). This has been reported as bug  # 971215-083826.- The window title.- Starting the GUI from the Terminal version with :gui always acts as if  :gui -f were used. There is no way to fix this that I can see.- There are some small display glitches here and there that I hope to clean up  later. Most of them occur when the window is partially obscured. Some of  them seem to be bugs in BeOS, because the Terminal has similar glitches.- Mouse up events are not generated when outside the window. This is a bug in  BeOS. You can notice this when selecting text and moving the cursor outside  the window, then letting go of the mouse button.  Another way is when you  drag the scrollbar and do the same thing.  Because Vim still thinks you are  still playing with the scrollbar it won't change it itself. I provided a  workaround which kicks in when the window is activated or deactivated (so it  works best with focus- follows-mouse (/boot/bin/ffm) turned on).- The cursor does not flash (very low priority; I'm not sure I even like it  when it flashes)							*beos-vimdir*The $VIM directory$VIM is the symbolic name for the place where Vims support files are stored.The default value for $VIM is set at compile time and can be determined with>  :versionThe normal value is /boot/home/config/share/vim. If you don't like it you canset the VIM environment variable to override this, or set 'helpfile' in your.vimrc:>  if version >= 500>      set helpfile=~/vim/vim54/doc/help.txt>      syntax on>  endifDrag & Drop						*beos-dragndrop*You can drop files and directories on either the Vim icon (starts a new Vimsession, unless you use the File Types application to set Vim to be "SingleLaunch") or on the Vim window (starts editing the files).  Dropping a foldersets Vim's current working directory. |:cd| |:pwd| If you drop files orfolders with either SHIFT key pressed, Vim changes directory to the folderthat contains the first item dropped. When starting Vim, there is no need topress shift: Vim behaves as if you do.Files dropped set the current argument list. |argument-list|Single Launch vs. Multiple Launch			*beos-launch*As distributed Vim's Application Flags (as seen in the FileTypes preference)are set to Multiple Launch. If you prefer, you can set them to Single Launchinstead.  Attempts to start a second copy of Vim will cause the first Vim toopen the files instead. This works from the Tracker but also from the commandline. In the latter case, non-file (option) arguments are not supported.NB: Only the GUI version has a BApplication (and hence Application Flags).This section does not apply to the GUI-less version, should you compile one.Fonts							*beos-fonts*Set fonts with>  :set guifont=Courier10_BT/Roman/10where the first part is the font family, the second part the style, and thethird part the size. You can use underscores instead of spaces in family andstyle.Best results are obtained with monospaced fonts (such as Courier). Vimattempts to use all fonts in B_FIXED_SPACING mode but apparently this does notwork for proportional fonts (despite what the BeBook says).Vim also tries to use the B_ISO8859_1 encoding, also known as ISO Latin 1.This also does not work for all fonts. It does work for Courier, but not forProFontISOLatin1/Regular (strangely enough). You can verify this by giving the>  :digraphscommand, which lists a bunch of characters with their ISO Latin 1 encoding.If, for instance, there are "box" characters among them, or the last characterisn't a dotted-y, then for this font the encoding does not work.If the font you specify is unavailable, you get the system fixed font.Standard fixed-width system fonts are:	      ProFontISOLatin1/Regular		  Courier10_BT/Roman		  Courier10_BT/Italic		  Courier10_BT/Bold		  Courier10_BT/Bold_ItalicStandard proportional system fonts are:		    Swis721_BT/Roman		    Swis721_BT/Italic		    Swis721_BT/Bold		    Swis721_BT/Bold_Italic		Dutch801_Rm_BT/Roman		Dutch801_Rm_BT/Italic		Dutch801_Rm_BT/Bold		Dutch801_Rm_BT/Bold_Italic		   Baskerville/Roman		   Baskerville/Italic		   Baskerville/Bold		   Baskerville/Bold_Italic		 SymbolProp_BT/RegularTry some of them, just for fun.The meta key modifier					*beos-meta*The META key modifier is obtained by the left or right OPTION keys.  This isbecause the ALT (aka COMMAND) keys are not passed to applications.Mouse key mappings					*beos-mouse*Vim calls the various mouse buttons LeftMouse, MiddleMouse and RightMouse.  Ifyou use the default Mouse preference settings these names indeed correspond toreality. Vim uses this mapping:    Button 1 -> LeftMouse,    Button 2 -> RightMouse,    Button 3 -> MiddleMouse.If your mouse has fewer than 3 buttons you can provide your own mapping frommouse clicks with modifier(s) to other mouse buttons. See the filevim-5.x/macros/swapmous.vim for an example.		|gui-mouse-mapping|Color names						*beos-colors*Vim has a number of color names built-in. Additional names are read from thefile $VIMRUNTIME/rgb.txt, if present. This file is basically the colordatabase from X. Names used from this file are cached for efficiency.Compiling with Perl					*beos-perl*Compiling with Perl support enabled is slightly tricky. The Metrowerkscompiler has some strange ideas where to search for include files. Sinceseveral include files with Perl have the same names as some Vim headerfiles, the wrong ones get included. To fix this, run the following Perlscript while in the vim-5.0/src directory:>   preproc.pl > perl.h    #!/bin/env perl    # Simple #include expander, just good enough for the Perl header files.    use strict;    use IO::File;    use Config;    sub doinclude    {	my $filename = $_[0];	my $fh = new IO::File($filename, "r");	if (defined $fh) {	    print "/* Start of $filename */\n";	    while (<$fh>) {		if (/^#include "(.*)"/) {		    doinclude($1);		    print "/* Back in $filename */\n";		} else {		    print $_;		}	    }	    print "/* End of $filename */\n";	    undef $fh;	} else {	    print "/* Cannot open $filename */\n";	    print "#include \"$filename\"\n";	}    }    chdir     $Config{installarchlib}."/CORE";    doinclude "perl.h";It expands the "perl.h" header file, using only other Perl header files.Now you can configure & make Vim without the --disable-perlinterp option.Be warned though that this adds about 616 kilobytes to the size of Vim!Without Perl, Vim with default features and GUI is about 575K, with Perlit is about 1191K.WARNING: Intel "architecture" detected!			*beos-ppc*or, Waiter, there is a fly in my soup!This means that you have made a poor choice of hardware platform.You'll be pleased to know that the Intel (compatibe) CPU that's insideyour computer is nothing more than a souped-up 8-bit machine. Or perhaps Ishould not say that: it's an insult to other 8-bit CPUs.However, apart from the occasional derisory remark, you have nothing to fearfrom Vim. If you don't like them, "Use The Source, Luke!", and remove them.However, the copyright that I claim on the files os_beos* and gui_beos*prevents you from making your changed version available to others.I don't think this is an unreasonable limitation.-Olaf Seibert<rhialto@polder.ubc.kun.nl>http://polder.ubc.kun.nl/~rhialto/be vim:ts=8:sw=8:tw=78:fo=tcq2:isk=!-~,^*,^\|,^\":

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -