org-mode

Emacs org-mode file/viewer associations

我与影子孤独终老i 提交于 2019-12-05 09:40:22
问题 In an Emacs org-mode file, when I click on a PDF the file opens in a PDF viewer. Similarly, when I click on a URL it opens in a web browser. But when I click on a path to an image file, the byte stream opens as text in the editor. How do I configure Emacs/org-mode to open images with a specified application, say an image editor or a browser? 回答1: In org-mode, this is org-file-apps that control what to do when clicking on a URL-like text. It is configured by default to : ((auto-mode . emacs) (

Code blocks inside tables for org-mode

荒凉一梦 提交于 2019-12-05 08:23:37
I love org-tables , I use them to document all sorts of things. I was now documenting some one-liners for Nix (after reading this excellent guide by Domen Kožar, given at this year's EuroPython ), and I got into some problems: * NIX Oneliners |------------------+---------------------------------------------+------------------------------| | DATE | COMMAND | DESCRIPTION | |------------------+---------------------------------------------+------------------------------| | <2014-07-24 Thu> | curl -L http://git.io/nix-install.sh § bash | Install nix | | <2014-07-24 Thu> | nix-env -qaP § grep

Orgmode: Show number of children under heading

 ̄綄美尐妖づ 提交于 2019-12-05 08:06:03
I have a heading in my orgmode file. It is automatically updated periodically with new children. I want the heading line to show the number of children. So if I have one child it would say something like (1) * Heading (1) ** Subheading After it gets updated with another subheading the number should automatically be changed to (2) * Heading (2) ** Subheading ** A new added subheading I want it to do this because the toplevel heading will normally be collapsed. I want to be able to see if any new children were added to it without having to expand it What's most similar to what you're searching

lazy loading of only the first N lines in emacs org-mode

ぃ、小莉子 提交于 2019-12-05 08:00:45
Is there a way to tell org-mode to load only the first N lines of a long text file? I would like to keep the whole file open to be able to search through it, but have org-mode display on the first N lines of my file, which is where I edit new content. If you have a structured outline in org-mode, you can set the global file visibility with the #+STARTUP markup, or the visibility of any heading with the VISIBILITY property, see Visibility Cycling for details. The benefit of using the built-in org-mode properties is that it's easy to have a file open up in exactly the state you want. I have my

How can I use other heading styles like twiki ---+ or mediawiki == h2 == in org-mode?

假如想象 提交于 2019-12-05 07:54:36
I really want to use org-mode. But, I want to use org-mode to understand structured documents that have already been written using different heading syntax, e.g. using twiki's ---+ ---+ H1 Top level ---++ H2 Nested ---+ H1 #2 Second top level Or mediawiki like = H1 = Top level == H2 == Nested = H1 #2 = Second top level I'd like to have all of the goodness of org-mode folding, etc., just using these different heading styles. Actually, worse that that: I would like, say, the twiki or mediawaiki headings to take priority over org mode asterisk headings. But I would like to have both in use. = H1

Microsoft Word to Org-mode

时间秒杀一切 提交于 2019-12-05 07:54:23
I am trying to put the Microsoft Word document in emacs using org-mode. I have copied the Word Document and pasted in emacs. I like to achieve the headings like 7.1.2.4 in org-mode format. and then link the TOC to appropriate headings. How I can do that? Any suggestions? Any programming language like Perl has done it? Thanks. There is ODT2ORG ( https://bitbucket.org/josemaria.alkala/odt2org/wiki/Home ) which lets you import odt files in org-mode. Use Openoffice/Libreoffice to produce an .odt from your .doc. Use odt2org to get an .org. About the headings: I am not entirely sure I understand you

FlySpell in Org-Mode recognize latex syntax like auctex

和自甴很熟 提交于 2019-12-05 06:38:23
Original Response: I was trying to figure out how in auctex mode latex doesn't seem to highlight any latex functions with flyspell turned on. Is this a custom dictionary file or how is this implemented? Can this be easily incorporated into an org-mode file so it doesn't highlight inserted latex code that will get exported. Edit: Simple example taken from top of file and in the text. Basically so latex syntax like ref or label inside {} won't be spell checked (this has been fixed by using (setq ispell-parser tex). Then also setting up a function that specific labels with #+ as the first text on

Emacs org-mode agenda filter by owner

孤者浪人 提交于 2019-12-05 03:35:34
Is it possible to filter agenda in emacs based on Owner property? Currently I use tags to set owner of TODO items. This way I can filter agenda by tags like this: (setq org-agenda-custom-commands `(("o" "tasks for oleg" ((org-agenda-list) (org-agenda-filter-apply ,(list "+oleg"))) ((org-agenda-remove-tags t))) ("k" "tasks for karl" ((org-agenda-list) (org-agenda-filter-apply ,(list "+karl"))) ((org-agenda-remove-tags t))) )) It's not convenient to use tags to mark the owner but I see no other way to filter TODO items by Owner. This worked for me in my .emacs: (setq org-agenda-custom-commands

How to set a buffer locally face attribute for a particular buffer?

浪尽此生 提交于 2019-12-05 03:24:50
I want to change the face attribute in Org-Agenda buffer only. So I need to change Org-Agenda face attribute buffer locally . Here is my code: (which is globally) (defun my-org-agenda-hl-line () (hl-line-mode) (set-face-attribute 'hl-line nil :box '(:color "deep pink" :line-width 2)) ) (add-hook 'org-agenda-mode-hook 'my-org-agenda-hl-line) Please to help me make this buffer locally. Thanks Here is what you need to do: ;; First create new face which is a copy of hl-line-face (copy-face 'hl-line 'hl-line-agenda-face) ;; Change what you want in this new face (set-face-attribute 'hl-line-agenda

How to align the calendar with week number as the intermonth-text

房东的猫 提交于 2019-12-05 02:50:42
When I use Emacs calendar/diary with org-mode(however I do not think this is the reason of the problem), I encounter the following problem. The default calendar is like this: I add the following codes to display week number: (copy-face font-lock-constant-face 'calendar-iso-week-face) (set-face-attribute 'calendar-iso-week-face nil :height 1) (setq calendar-intermonth-text '(propertize (format "%2d" (car (calendar-iso-from-absolute (calendar-absolute-from-gregorian (list month day year))))) 'font-lock-face 'calendar-iso-week-face)) ; Title for week number (copy-face 'default 'calendar-iso-week