Browse Source

Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode

Carsten Dominik 15 years ago
parent
commit
ae91c0cb0c
6 changed files with 154 additions and 18 deletions
  1. 124 7
      ORGWEBPAGE/Changes.org
  2. 7 3
      ORGWEBPAGE/index.org
  3. 1 1
      contrib/lisp/org-mime.el
  4. 19 4
      doc/org.texi
  5. 2 2
      lisp/ob.el
  6. 1 1
      lisp/org-timer.el

+ 124 - 7
ORGWEBPAGE/Changes.org

@@ -30,6 +30,62 @@ the root of the org-mode repository.
 Failure to update this repository will cause loading of
 Failure to update this repository will cause loading of
 org-test.el to throw errors.
 org-test.el to throw errors.
 ** Details
 ** Details
+*** Fontify code in code blocks.
+
+Source code in code block can now be fontified.  Please customize
+the varable =org-src-fontify-natively=, but be prepared for some
+editing delays in large blocks.  Thanks to Dan Davison for this.
+
+*** Language-mode commands are available in the Org-buffer
+    The most general machinery for doing this is the macro
+    `org-babel-do-in-edit-buffer'. There is also the convenience
+    function `org-babel-do-key-sequence-in-edit-buffer' which makes
+    use of this macro, and is bound to C-c C-v C-x and C-c C-v x. If
+    there is an active region contained within the code block, then
+    this is inherited by the edit buffer. Some examples of the sorts
+    of usage this permits are
+
+C-c C-v C-x M-;       comment region according to language
+C-c C-v C-x C-M-\     indent region according to language
+
+Users can make these more convenient, e.g.
+
+(defun my/org-comment-dwim (&optional arg)
+    (interactive "P")
+    (or (org-babel-do-key-sequence-in-edit-buffer "\M-;")
+        (comment-dwim arg)))
+
+(define-key org-mode-map "\M-;" 'my/org-comment-dwim)
+
+A common instance of this general pattern is built in to Org-mode,
+controlled by the variable `org-src-tab-acts-natively': if this
+variable is set, then TAB in a code block has the effect that it would
+have in the language major mode buffer.
+
+*** Org-babel commands are available in language-mode edit buffer
+    Mirroring the language-native commands in Org buffers above, a new
+    macro `org-src-do-at-code-block' and convenience function
+    `org-src-do-key-sequence-at-code-block' provide the converse. When
+    used in a language major-mode edit buffer (i.e. a buffer generated
+    by C-c '), `org-src-do-key-sequence-at-code-block' executes a key
+    sequence at the code block in the source Org buffer.  The command
+    bound to the key sequence in the Org-babel key map is executed
+    remotely with point temporarily at the start of the code block in
+    the Org buffer.
+
+    The command is not bound to a key by default, to avoid conflicts
+    with language major mode bindings. To bind it to C-c @ in all
+    language major modes, you could use
+
+  (add-hook 'org-src-mode-hook
+            (lambda () (define-key org-src-mode-map "\C-c@"
+                    'org-src-do-key-sequence-at-code-block)))
+
+    In that case, for example, C-c @ t issued in code edit buffers
+    would tangle the current Org code block, C-c @ e would execute
+    the block and C-c @ h would display the other available
+    Org-babel commands.
+
 *** Multi-line header arguments to code blocks
 *** Multi-line header arguments to code blocks
 Code block header arguments can now span multiple lines using the
 Code block header arguments can now span multiple lines using the
 new =#+header:= or =#+headers:= lines preceding a code block or
 new =#+header:= or =#+headers:= lines preceding a code block or
@@ -85,6 +141,55 @@ can provide intuition for the new behavior.
   ,: 0.254227238707244
   ,: 0.254227238707244
 #+end_src
 #+end_src
 
 
+*** Added :headers header argument for LaTeX code blocks
+This makes it possible to set LaTeX options which must take place in
+the document pre-amble for LaTeX code blocks.  This header argument
+accepts either a single string or a list, e.g.
+
+#+begin_src org
+  ,#+begin_src latex :headers \usepackage{lmodern} :file name1.pdf
+  ,  latex body
+  ,#+end_src
+  
+  ,#+begin_src latex :headers '("\\usepackage{mathpazo}" "\\usepackage{fullpage}") :file name2.pdf
+  ,  latex body
+  ,#+end_src
+#+end_src
+
+*** New function `org-export-string'
+Allows exporting directly from a string to the specified export format.
+*** Code block header argument ":noweb tangle"
+Only expands <<noweb>> syntax references when tangling, not during
+export (weaving).
+*** New function `org-babel-switch-to-session-with-code'
+C-c C-v z (`org-babel-switch-to-session-with-code') is a variant of
+C-c C-v C-z (`org-babel-switch-to-session'): instead of switching to
+the session buffer, it splits the window between (a) the session
+buffer and (b) a language major-mode edit buffer for the code block in
+question. This can be convenient for using language major mode for
+interacting with the session buffer.
+
+*** Improvements to R sessions
+    R now uses standard ESS code evaluation machinery in the :results
+    value case, which avoids unnecessary output to the comint
+    buffer. In addition, the R command responsible for writing the
+    result to file is hidden from the user.  Finally, the R code edit
+    buffer generated by C-c ' is automatically linked to the ESS
+    session if the current code block is using :session.
+
+*** Temporary file directory
+All babel temporary files are now kept in a single sub-directory in
+the /tmp directory and are cleaned up when Emacs exits.
+
+*** Function for demarcating blocks `org-babel-demarcate-block'
+Can be called to wrap the region in a block, or to split the block
+around point, bound to (C-c C-v d).
+
+*** Function for marking code block contents `org-babel-mark-block'
+    Bound to C-M-h in the babel key map (i.e. C-c C-v C-M-h by
+    default).  This can be useful in conjunction with
+    `org-babel-do-in-edit-buffer', for example for language-native
+    commenting or indenting of the whole block.
 *** Lists of anniversaries are now handeled better
 *** Lists of anniversaries are now handeled better
 
 
 When several anniversaries are defined in the bbdb anniversaries
 When several anniversaries are defined in the bbdb anniversaries
@@ -147,8 +252,21 @@ documentation of MobileOrg and Appendix B of the manual for more
 details.
 details.
 
 
 *** LaTeX minted package for fontified source code export
 *** LaTeX minted package for fontified source code export
+Patch by Dan Davison.
+
+A non-nil value of `org-export-latex-minted' means to export source
+code using the minted package, which will fontify source code
+with color.  If you want to use this, you need to make LaTeX use the
+minted package. Add minted to `org-export-latex-packages-alist', for
+example using customize, or with something like
+
+  (require 'org-latex)
+  (add-to-list 'org-export-latex-packages-alist '("" "minted"))
 
 
-Patch by Dan Davison FIXME
+In addition, it is neccessary to install
+pygments (http://pygments.org), and to configure
+`org-latex-to-pdf-process' so that the -shell-escape option is
+passed to pdflatex.
     
     
 *** MobileOrg: Do not force to insert IDs
 *** MobileOrg: Do not force to insert IDs
 
 
@@ -185,12 +303,6 @@ property upon export.
 
 
 Thanks to David Maus for a patch to this effect.
 Thanks to David Maus for a patch to this effect.
 
 
-*** Fontify code in code blocks.
-
-Source code in code block can now be fontified.  Please customize
-the varable =org-src-fontify-natively=, but be prepared for some
-editing delays in larger blocks.  Thanks to Dan Davison for this.
-
 *** LaTeX package fixes
 *** LaTeX package fixes
 
 
 We updated the list of default packages loaded by LaTeX exported
 We updated the list of default packages loaded by LaTeX exported
@@ -255,6 +367,11 @@ possible with org-wikinodes.el, which is available in the contrib
 directory.  We also have some [[http://orgmode.org/worg/org-contrib/org-wikinodes.php][documentation]] for this feature up
 directory.  We also have some [[http://orgmode.org/worg/org-contrib/org-wikinodes.php][documentation]] for this feature up
 on Worg.
 on Worg.
 
 
+*** Timer/clock enhancements
+
+=org-timer-set-timer= displays a countdow timer in the modeline.
+From the agenda, `J' invokes =org-agenda-clock-goto=.
+
 * Version 7.01
 * Version 7.01
 :PROPERTIES:
 :PROPERTIES:
 :CUSTOM_ID: v7.01
 :CUSTOM_ID: v7.01

+ 7 - 3
ORGWEBPAGE/index.org

@@ -154,7 +154,8 @@ get a local clone of the repository use something like the following
 Some more information about this can be found in the [[http://orgmode.org/worg/org-faq.php][FAQ]], under [[http://orgmode.org/worg/org-faq.php#keeping-current-with-Org-mode-development][How do
 Some more information about this can be found in the [[http://orgmode.org/worg/org-faq.php][FAQ]], under [[http://orgmode.org/worg/org-faq.php#keeping-current-with-Org-mode-development][How do
 I keep current with Org mode development?]].  For people who cannot use
 I keep current with Org mode development?]].  For people who cannot use
 git, we provide [[file:org-latest.zip][zip]] or [[file:org-latest.tar.gz][tar.gz]] snapshot release files updated each day
 git, we provide [[file:org-latest.zip][zip]] or [[file:org-latest.tar.gz][tar.gz]] snapshot release files updated each day
-and corresponding to the latest git version.
+and corresponding to the latest git version.  Alternatively, you can
+also download a [[http://repo.or.cz/w/org-mode.git/snapshot][tar.gz snapshot]] from the repo.or.cz server.
 
 
 ** Alternative distributions
 ** Alternative distributions
 
 
@@ -213,10 +214,13 @@ and corresponding to the latest git version.
 
 
    - [[http://lists.gnu.org/mailman/listinfo/emacs-orgmode][Subscribe to it]] at the web interface.
    - [[http://lists.gnu.org/mailman/listinfo/emacs-orgmode][Subscribe to it]] at the web interface.
    - Directly [[mailto:emacs-orgmode@gnu.org][send mail to it]].  If you are not subscribed, a moderator
    - Directly [[mailto:emacs-orgmode@gnu.org][send mail to it]].  If you are not subscribed, a moderator
-     will look at the message before passing it through to the
-     list.
+     will look at the message before passing it through to the list.
    - Read the list on [[http://www.gmane.org][Gmane]] through a [[http://news.gmane.org/gmane.emacs.orgmode][web interface]] or with a
    - Read the list on [[http://www.gmane.org][Gmane]] through a [[http://news.gmane.org/gmane.emacs.orgmode][web interface]] or with a
      [[news://news.gmane.org/gmane.emacs.orgmode][newsreader]].
      [[news://news.gmane.org/gmane.emacs.orgmode][newsreader]].
+   - Please read the [[http://orgmode.org/manual/Feedback.html][Feedback]] section of Org's manual before posting a
+     question, it helps getting useful answer.  [[http://www.catb.org/esr/faqs/smart-questions.html][How To Ask Questions
+     The Smart Way]], by E. S. Raymond is also worth reading.
+
 
 
 #+BEGIN_HTML
 #+BEGIN_HTML
 </li><li><form method="get" action="http://search.gmane.org/"><div>
 </li><li><form method="get" action="http://search.gmane.org/"><div>

+ 1 - 1
contrib/lisp/org-mime.el

@@ -185,7 +185,7 @@ export that region, otherwise export the entire body."
          ;; to hold attachments for inline html images
          ;; to hold attachments for inline html images
          (html-and-images
          (html-and-images
           (org-mime-replace-images
           (org-mime-replace-images
-           (org-mime-org-export "html" raw-body tmp-file)
+           (org-export-string raw-body "html" (file-name-directory tmp-file))
            tmp-file))
            tmp-file))
          (html-images (unless arg (cdr html-and-images)))
          (html-images (unless arg (cdr html-and-images)))
          (html (org-mime-apply-html-hook
          (html (org-mime-apply-html-hook

+ 19 - 4
doc/org.texi

@@ -263,6 +263,7 @@ Dates and times
 * Resolving idle time::         Resolving time if you've been idle
 * Resolving idle time::         Resolving time if you've been idle
 * Effort estimates::            Planning work effort in advance
 * Effort estimates::            Planning work effort in advance
 * Relative timer::              Notes with a running timer
 * Relative timer::              Notes with a running timer
+* Countdown timer::             Starting a countdown timer for a task
 
 
 Creating timestamps
 Creating timestamps
 
 
@@ -1327,7 +1328,7 @@ structure of these lists, many structural constructs like @code{#+BEGIN_...}
 blocks can be indented to signal that they should be considered of a list
 blocks can be indented to signal that they should be considered of a list
 item.
 item.
 
 
-@Vindex org-list-demote-modify-bullet
+@vindex org-list-demote-modify-bullet
 If you find that using a different bullet for a sub-list (than that used for
 If you find that using a different bullet for a sub-list (than that used for
 the current list-level) improves readability, customize the variable
 the current list-level) improves readability, customize the variable
 @code{org-list-demote-modify-bullet}.
 @code{org-list-demote-modify-bullet}.
@@ -1726,8 +1727,7 @@ table.  But it's easier just to start typing, like
 @item C-c C-c
 @item C-c C-c
 Re-align the table without moving the cursor.
 Re-align the table without moving the cursor.
 @c
 @c
-@kindex @key{TAB}
-@item @key{TAB}
+@orgcmd{<TAB>,org-cycle}
 Re-align the table, move to the next field.  Creates a new row if
 Re-align the table, move to the next field.  Creates a new row if
 necessary.
 necessary.
 @c
 @c
@@ -5013,6 +5013,7 @@ is used in a much wider sense.
 * Resolving idle time::         Resolving time if you've been idle
 * Resolving idle time::         Resolving time if you've been idle
 * Effort estimates::            Planning work effort in advance
 * Effort estimates::            Planning work effort in advance
 * Relative timer::              Notes with a running timer
 * Relative timer::              Notes with a running timer
+* Countdown timer::             Starting a countdown timer for a task
 @end menu
 @end menu
 
 
 
 
@@ -5874,7 +5875,7 @@ with the @kbd{/} key in the agenda (@pxref{Agenda commands}).  If you have
 these estimates defined consistently, two or three key presses will narrow
 these estimates defined consistently, two or three key presses will narrow
 down the list to stuff that fits into an available time slot.
 down the list to stuff that fits into an available time slot.
 
 
-@node Relative timer,  , Effort estimates, Dates and Times
+@node Relative timer, Countdown timer, Effort estimates, Dates and Times
 @section Taking notes with a relative timer
 @section Taking notes with a relative timer
 @cindex relative timer
 @cindex relative timer
 
 
@@ -5916,6 +5917,20 @@ by a certain amount.  This can be used to fix timer strings if the timer was
 not started at exactly the right moment.
 not started at exactly the right moment.
 @end table
 @end table
 
 
+@node Countdown timer,  , Relative timer, Dates and Times
+@section Countdown timer
+@cindex Countdown timer
+@kindex C-c C-x ;
+@kindex ;
+
+Calling @code{org-timer-set-timer} from an Org-mode buffer runs a countdown
+timer.  Use @key{;} from agenda buffers, @key{C-c C-x ;} everwhere else.
+
+@code{org-timer-set-timer} prompts the user for a duration and displays a
+countdown timer in the modeline.  @code{org-timer-default-timer} sets the
+default countdown value.  Giving a prefix numeric argument overrides this
+default value.
+
 @node Capture - Refile - Archive, Agenda Views, Dates and Times, Top
 @node Capture - Refile - Archive, Agenda Views, Dates and Times, Top
 @chapter Capture - Refile - Archive
 @chapter Capture - Refile - Archive
 @cindex capture
 @cindex capture

+ 2 - 2
lisp/ob.el

@@ -178,11 +178,11 @@ Returns a list
 		   (nth 2 info))))
 		   (nth 2 info))))
 	  (when (looking-at org-babel-src-name-w-name-regexp)
 	  (when (looking-at org-babel-src-name-w-name-regexp)
 	    (setq name (org-babel-clean-text-properties (match-string 4)))
 	    (setq name (org-babel-clean-text-properties (match-string 4)))
-	    (when (match-string 5)
+	    (when (match-string 6)
 	      (setf (nth 2 info) ;; merge functional-syntax vars and header-args
 	      (setf (nth 2 info) ;; merge functional-syntax vars and header-args
 		    (org-babel-merge-params
 		    (org-babel-merge-params
 		     (mapcar (lambda (ref) (cons :var ref))
 		     (mapcar (lambda (ref) (cons :var ref))
-			     (org-babel-ref-split-args (match-string 5)))
+			     (org-babel-ref-split-args (match-string 6)))
 		     (nth 2 info))))))
 		     (nth 2 info))))))
       ;; inline source block
       ;; inline source block
       (when (save-excursion (re-search-backward "[ \f\t\n\r\v]" nil t)
       (when (save-excursion (re-search-backward "[ \f\t\n\r\v]" nil t)

+ 1 - 1
lisp/org-timer.el

@@ -328,7 +328,7 @@ VALUE can be `on', `off', or `pause'."
 
 
 If `org-timer-default-timer' is not zero, suggest this value as
 If `org-timer-default-timer' is not zero, suggest this value as
 the default duration for the timer.  If a timer is already set,
 the default duration for the timer.  If a timer is already set,
-prompt the use if she wants to replace it.
+prompt the user if she wants to replace it.
 
 
 Called with a numeric prefix argument, use this numeric value as
 Called with a numeric prefix argument, use this numeric value as
 the duration of the timer.
 the duration of the timer.