i have always defined matrices of two dimensions as a vector of a vector container as follows however i recently learned that c++0x allows one to get rid of the extra space between the right angle brackets as in the following however emacs 23 breaks indentation when faced with this format i also use 3 [...]
Archive for the ‘emacs’ Category
emacs breaks indentation for C++0x angle brackets
Posted in c++, emacs, tagged c++, c++0x, code indentation, emacs on January 7, 2011 | Leave a Comment »
emacs color theme
Posted in emacs, tagged color theme tango, elisp, emacs on July 4, 2010 | 4 Comments »
been working with the default color scheme that comes with emacs on archlinux. most of the times i found that after long sessions and particularly at night my eyes would hurt looking at a white background. though i have an lcd screen but the white was too much. so i started looking for a dark [...]
emacs maximized
Posted in emacs, tagged bash, emacs on June 27, 2010 | 3 Comments »
back when i was on ubuntu hardy heron i used the following in my .emacs to maximize the emacs window on startup now that i am on archlinux with emacs 23.2.1 i follow a different strategy i have defined the following function in my .bashrc the reason i defined a function and not an alias [...]
install yasnippet on archlinux
Posted in emacs, tagged archlinux, emacs, yasnippet on June 19, 2010 | Leave a Comment »
yasnippet is not available in the archlinux repos so we will install it from the AUR first go to AUR home and search for yasnippet … u will get the following page http://aur.archlinux.org/packages.php?ID=18440 download the tarball from that page .. in my case the link to the tarball was http://aur.archlinux.org/packages/emacs-yasnippet/emacs-yasnippet.tar.gz put the tarball in a [...]
emacs c++ tags
Posted in c++, emacs on March 30, 2010 | 2 Comments »
source code navigation using tags is a lifesaver in large projects … i have been using the system for sometime but was vexed with a problem for a long time. i m on ubuntu 8.04 which has the exuberant ctags package available. my makefiles have a phony target called `tags’ that generate the TAGS file [...]
emacs confine search and/or replace within a c++ function
Posted in c++, emacs, tagged c++, emacs, linux on March 10, 2010 | Leave a Comment »
in a typical c++ file i have many functions and many a times i needed to search a keyword/variable or carry out a search and replace operation … however it becomes very confusing if multiple functions exist that use the same variable names. often times i keep hitting C-s and i never can know if [...]
emacs cpu hog
Posted in emacs, linux on March 6, 2010 | Leave a Comment »
i m on ubuntu 8.04 ( hardy heron ) and every once in a while emacs freezes … i use htop to find out that emacs and X are hogging up cpu cycles … when i kill emacs it all returns to normal. some times i see the same thing happening when i have firefox [...]
emacs find next occurrence of tag OR “C-u M-.” made easier to type
Posted in emacs on March 3, 2010 | 3 Comments »
in emacs one may use tags to navigate source code. i use etags to generate a tags list for my source code tree and then to navigate one simply needs to hit which stands for now to find the next occurance of the same tag one needs to hit several times in succession to navigate [...]
emacs which c++ function am i in ?
Posted in c++, emacs on February 27, 2010 | 7 Comments »
some time when there are a lot of functions in a c++ file, one may get lost trying to figure out which funtion the current line belongs to. the problem is intensified when the function spans more than a couple screen fuls. and then there is an occasional C-s ( incremental search ) which will [...]
change default name of tags file in emacs
Posted in c++, emacs on November 17, 2009 | 4 Comments »
i use etags to generate a TAGS file that allows me to navigate through source code of c++ projects that i work on. the default name for the file that contains the tags is TAGS so everytime i had to type make TAGS in order to generate the tags file. i hate typing capital letters [...]