-
字母、数字、控制键
h,j,k,l四个方向键:h向左,j向下,k向上,l向右,这四个键让手不离盲打区域。gg和G:gg是回到文本文件的第一行,G是定位到文本文件的最后一行。- gD 跳转到局部变量的定义处
- % 跳转到配对的括号上
- [[ 跳转到代码块的开头去
- '' 跳转到光标上次停靠的地方
- mx 设置书签
- `x 跳转到书签处
w是跳到下一个单词的开头,W是跳到以空格分隔的下一个单词的开头,w表示word。e是跳到下一个单词的结尾,E是跳到以空格分隔的下一个单词的结尾,e表示end。b是跳到前一个单词的开头,B是跳到以空格分隔的前一个单词的开头,b表示back。Ctrl+f是向前翻页,Ctrl+b是向后翻页,f表示forward,b表示backward。Ctrl+u是向前翻半页,Ctrl+d是向下翻半页,u表示up,d表示down。f+字母:表示向前定位到第一个找到的字母,比如fa表示向前定位到第一个字母a。F+字母:表示向后定位到第一个找到的字母。n+f+字母:表示向前定位到第n个找到的字母。n+F+字母:表示向后定位到第n个找到的字母。- 字符向前和向后定位都可以按分号
;定位下一个,按逗号,定位前一个。 ^跳到行首,$跳到行末,0跳到行首第一个非空字符。 如果发生折行,上述与行有关的命令可以加上g前缀用于操作屏幕上的行。o,O:向前向后新建编辑行n>; 增加n个tab缩进n<; 减少n个tab缩进- :!start{commmand} 异步调用外部命令
-
单词
xp: cut a character and paste after current 交换字符caw: change a word 修改一个单词d3k: delete 3 lines upwards 向上删除3行,同理d3j向下删除3行ddp: delete a line and paste after current line 交换两行zt将当前行置顶,zb将当前行置底,zz将当前行居中,t表示top,b表示bottom,而前缀z表示zoom。 最好用的翻页组合:按zz将当前行居中,然后按ctrl+u或者ctrl+d半屏翻页。
-
句子
V选中当前行,进入v模;按j或k多行选择;>或<整体缩进;
-
正则表达式
- Vim Reqular Expressions 101
- 单文件替换
- %s/pattern/replace/gc
- 5,6s/pattern/replace/gc
-
多文件
- :vimgrep /searchpattern/ [g][j] filepattern
- :vim多文件替换
- arg
- arg *.h
- arglist
- argdo
- argdo %s/pattern/replace/ge | update
-
参考资料
-
快捷键
Ctrl+Enter在上面打开新一行Ctrl+Shift+Enter在下面打开新一行Ctrl+-,Ctrl++,切换前后两个编辑位置Ctrl+K, Ctrl+CCtrl+K, Ctrl+U切换注释Ctrl+u, Ctrl+U切换选中文本大小写Ctrl+w选中单词- 当你在光标停留行使用快捷键
Ctrl+C,Ctrl+X,Ctrl+L时,可以复制,剪切,删除整行内容。
-
插件
-
Visual Studio 2008 多行批量替换
- Alt+F8
- Click
Samples->Utilities - Right Click
FindLine,ClickEdit - Modify the
FindLine Macro:
'' Add the following code DTE.Find.ReplaceWith = textSelection.Text- Save and close the macro edit window
- Select the multiline
Find Whatcode- Double Click
FindLineMacro - Close the Find Dialog
- Double Click
- Select the multiline
Replace Withcode- Double Click
FindLineMacro - Click the
Quick ReplaceTab in the Find Dialog - Select
Find Whatcode from context menu - Select
Replace Withcode from context menu - Click
FindNext - Test click
Replace - Now you can click
Replace All
- Double Click
-
Visual Studio 2008禁用智能提示
- 打开目录C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\vcpackages
- 重命名feacp.dll为feacp_disable.dll,或者删除之
- Visual Studio自带的智能提示总是会卡,而且会导致IDE经常死掉,还是禁用掉,用VA的
-
Visual Studio 2008设置代码导航线
- 打开注册表,找到HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\Text Editor
- 新建项Guides
- 写入值RGB(128,128,128) 4,75,80
- 其中,RGB表示颜色,4,75,80表示导航线的列位置,用逗号隔开,可以加入任意多条线
-
Visual Studio 2008美观设置
- 字体Lucida Console或者Source Code Pro
- LineNumber,背景色淡绿色,字体深灰色
- VA,当前行高亮采用DottedBox
- 在Addin目录下安装插件WordLight,高亮文件内选中文本的匹配项
- VA或者其他插件设置右侧地图式滚动面板
-
Visusl Studio Debug变慢的原因
You may need to delete all your breakpoints---note that you need to click the "delete all breakpoints" button (or use Ctrl-Shft-F9), NOT just delete them one by one. If Visual Studio has mangled your solution settings the latter will not work. You may need to add a breakpoint first, in order for this to work (clever, eh?).If worst comes to worst, you may need to delete your .suo file and let Visual Studio start a new one from scratch. Note that you will lose your personal solution configuration settings, however (only for this solution, not any others). However, you may want to move/rename the file temporarily until you determine whether or not this is the problem; that way, you can always move it back. I have seen some online resources recommend deleting (moving/renaming) the .ncb file as well.
- 快捷键
Ctrl+Shift+n:新建隐身窗口
Win+e:打开新文件夹Win+r:运行Win+l:锁定屏幕Win+i:Windows8右侧栏- 安装基于Chromium开发的Tab式文件管理器Clover
- 如果本地进行了一堆复杂操作后,发现提交的时候很多missing之类的冲突,最简单的办法是:
- 将当前文件夹的文件和子文件夹都
cut到某个空目录x - 对当前文件夹做
svn revert - 将x文件夹下的备份内容
copy回当前文件夹 - 重新执行
svn commit
- 将当前文件夹的文件和子文件夹都
- 对于QQ群,如果不想浪费时间的话,一定要把人多水多的群设置为「只显示消息数目,不弹出消息」,切记切记
- TeX example
- TeX wikibook
- TeX stackxchange
- CTeX
- LaTeX editor
- Introduce to TeX by 王垠
- LaTeX wiki
- Using Import graphics in LaTeX 2e
- PracTeX
- LaTeX comminity
- LaTeX Templates
- TeX tips
- A Beamer Quickstart
- Introduction to Beamer
- 在 MS Windows 裝 TeX Live 2011
- 最简单的 TeXLive CD 安装指南
- BibTeX Format
- TeXMacs (What you see is what you get)
- Visual Debugging in TEX
图片嵌入压缩包
环境:window+7zip
准备:a.jpg b.7z
制图命令:copy /b a.jpg+b.7z c.jpg
解压:重命名c.jpg 为c.7z,右键用7z解压。