From mboxrd@z Thu Jan 1 00:00:00 1970 From: mapcdi@me.com Subject: Re: fold paragraphs, export only contents of a node, hiding the 'node heading text' Date: Tue, 03 Sep 2013 16:48:21 +0200 Message-ID: References: <4702F1A4-113B-4171-B949-2B9EE14EEAA9@me.com> Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\)) Content-Type: multipart/alternative; boundary="Apple-Mail=_947CCBE6-48A4-4419-BF81-2564D8E6BE80" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33518) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGruP-0000lu-Dl for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 10:48:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VGruK-0007n2-Nl for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 10:48:45 -0400 Received: from nk11p04mm-asmtpout001.mac.com ([17.158.236.236]:36351 helo=nk11p04mm-asmtp001.mac.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGruK-0007mf-CJ for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 10:48:40 -0400 Received: from [10.0.1.13] (79.108.198.23.dyn.user.ono.com [79.108.198.23]) by nk11p04mm-asmtp001.mac.com (Oracle Communications Messaging Server 7u4-27.07(7.0.4.27.6) 64bit (built Jun 21 2013)) with ESMTPSA id <0MSK00C7O14LA920@nk11p04mm-asmtp001.mac.com> for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 14:48:25 +0000 (GMT) In-reply-to: <4702F1A4-113B-4171-B949-2B9EE14EEAA9@me.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: John Hendy Cc: emacs-orgmode --Apple-Mail=_947CCBE6-48A4-4419-BF81-2564D8E6BE80 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 So, now that I can hide all the headings I need a way to hide ONLY SOME = headings, like those with a todo-like specific text: say UNFINISHEDPAR = for unfinished paragraphs and FINISHEDPAR for the ones finished. Is it possible given the current (.emacs/test-file.org) working setup, = as a reminder: >> ;; change path to point to your org/lisp directory >> (add-to-list 'load-path "~/.elisp/org.git/lisp/") >>=20 >> (setq org-export-allow-bind-keywords t) >>=20 >> (defun mapcdi-org-latex-headline-function (todo todo-type priority = text tags) >> "The docstring of my function." >> (concat >> (and todo (format "{}" todo)) >> (and priority (format "{} " )) >> (and text (format "{\\vspace{-\\baselineskip}}" )) >> (and tags >> (format "\\hfill{}\\textit{}" (mapconcat 'identity tags = ":"))))) Thanks, Mark El 03/09/2013, a las 09:16, mapcdi@me.com escribi=F3: > >=20 >=20 > It works all right!=20 > I had org version 7.9 which seems the current 'bundled' version for = Emacs, which I recently installed (being a newbie, as I am, for = Emacs/Org-mode). I updated via > M-x package-install RET org > as in http://orgmode.org/org.html#Installation >=20 >=20 > and now I have 8.0.7. I compiled with your .emacs/.org example files, = except I needed to add: >=20 > (setenv "PATH" (concat (getenv "PATH") ":/usr/texbin")) > (setq exec-path (append exec-path '("/usr/texbin"))) >=20 > or it wouldn't compile the PDF, > and there's the output: success! >=20 >=20 > So, I will start tinkering myself with some settings like: > = http://tex.stackexchange.com/questions/39227/no-indent-in-the-first-paragr= aph-in-a-section >=20 >=20 > By the way, do you know how I could eliminate my needed line, in my = .emacs: > (setenv "PATH" (concat (getenv "PATH") ":/usr/texbin")) > (setq exec-path (append exec-path '("/usr/texbin"))) > by way of setting things to a default setting so I don't need to = update my path every time via .emacs. >=20 >=20 > Thanks! >=20 > Mark >=20 >=20 >=20 > El 03/09/2013, a las 03:32, John Hendy escribi=F3: >=20 >>=20 >>=20 >>=20 >> On Mon, Sep 2, 2013 at 4:53 PM, wrote: >> >>=20 >>=20 >>=20 >> After I compile: C-c C-e d (=85 to open PDF file). >> It asks: >> 'Allow BIND values in this buffer? (yes or no) ' >> I answer 'yes' and the PDF is opened. I have attached the resulting = PDF screen capture. >> Thanks. >>=20 >>=20 >> What is your orgmode version (paste the output of `M-x org-version`)? = I decided to just give a whirl with a minimal config and I don't think = that Org 8+ asks for allowing bind keywords anymore, or at least it = isn't asking me with 8.0.7. =46rom my tinkering, it looks like it = ignores them or you need to explictly allow them: >>=20 >> M-x customize-variable RET org-export-allow-bind-keywords RET >>=20 >> Hide Org Export Allow Bind Keywords: Toggle on (non-nil) >> State : CHANGED outside Customize. >> Non-nil means BIND keywords can define local variable values. Hide >> This is a potential security risk, which is why the default value >> is nil. You can also allow them through local buffer variables. >>=20 >> I could be wrong, but the "toggle" button (vs. stating possible = values) implies that it's either on or off. >>=20 >> Actually, in just searching now, it seems that this is, indeed, the = case since 8.0.3: >>=20 >> http://orgmode.org/Changes.html#sec-1-5-1 >>=20 >> In any case, I am now using this for my minimal config and it works = successfully: >>=20 >> #+begin_src >>=20 >> ;; change path to point to your org/lisp directory >> (add-to-list 'load-path "~/.elisp/org.git/lisp/") >>=20 >> (setq org-export-allow-bind-keywords t) >>=20 >> (defun mapcdi-org-latex-headline-function (todo todo-type priority = text tags) >> "The docstring of my function." >> (concat >> (and todo (format "{}" todo)) >> (and priority (format "{} " )) >> (and text (format "{\\vspace{-\\baselineskip}}" )) >> (and tags >> (format "\\hfill{}\\textit{}" (mapconcat 'identity tags = ":"))))) >>=20 >> #+end_src >> =20 >> And this is the file I'm using (I removed anything non-essential to = eliminate other possible causes): >>=20 >> #+begin_src >>=20 >> #+options: num:nil >> #+bind: org-latex-format-headline-function = mapcdi-org-latex-headline-function >>=20 >>=20 >>=20 >> * headline 1 >>=20 >> blah blah blah. >>=20 >> * headline 2 >>=20 >> blah blah blah >>=20 >> * headline 3 >>=20 >> A couple of separate paragraphs to see how far apart two paragraphs = would be >> normally. We'll add enough to line break just to make it interesting. >>=20 >> A couple of separate paragraphs to see how far apart two paragraphs = would be >> normally. We'll add enough to line break just to make it interesting. >>=20 >> #+end_src >>=20 >>=20 >> I attached a screenshot of the result! >>=20 >>=20 >> Let me know if that helps, >> John >>=20 >>=20 >>=20 >> My test-file, OrgMode.org: >>=20 >> #+TITLE: My file is OrgMode.org >> #+AUTHOR: =20 >> #+EMAIL: =20 >> #+DATE: =20 >> #+DESCRIPTION: >> #+KEYWORDS: >> #+LANGUAGE: en >> #+BIND: org-latex-format-headline-function = mapcdi-org-latex-headline-function >> #+OPTIONS: H:3 num:nil toc:t \n:nil @:t ::t |:t ^:t=20 >> #+OPTIONS: -:t f:t *:t <:t tasks:nil >> #+OPTIONS: pri:nil tags:not-in-toc >> #+OPTIONS: TeX:t LaTeX:t skip:nil d:nil todo:t=20 >> #+INFOJS_OPT: view:nil toc:nil ltoc:t mouse:underline buttons:0 = path:http://orgmode.org/org-info.js >> #+EXPORT_SELECT_TAGS: export >> #+EXPORT_EXCLUDE_TAGS: noexport >> #+LINK_UP: =20 >> #+LINK_HOME:=20 >> #+XSLT: >>=20 >> * TODO headline 1 = :test: >>=20 >> blah blah blah. >>=20 >> * headline 2 >>=20 >> blah blah blah >>=20 >> * headline 3 >>=20 >> A couple of separate paragraphs to see how far apart two paragraphs = would be >> normally. We'll add enough to line break just to make it interesting. >>=20 >> A couple of separate paragraphs to see how far apart two paragraphs = would be >> normally. We'll add enough to line break just to make it interesting. >>=20 >>=20 >>=20 >>=20 >> ____________________________________________________________________ >> My .emacs file >>=20 >> (custom-set-variables >> ;; custom-set-variables was added by Custom. >> ;; If you edit it by hand, you could mess it up, so be careful. >> ;; Your init file should contain only one such instance. >> ;; If there is more than one, they won't work right. >> '(adaptive-fill-mode nil) >> '(blink-cursor-mode nil) >> '(column-number-mode t) >> '(current-language-environment "Spanish") >> '(debug-on-error t) >> '(debug-on-quit t) >> '(display-battery-mode t) >> '(display-time-mode t) >> '(fill-column 56) >> '(left-margin 0) >> '(ns-alternate-modifier (quote meta)) >> '(ns-command-modifier (quote super)) >> '(ns-function-modifier (quote none)) >> '(ns-right-alternate-modifier (quote none)) >> '(ns-right-command-modifier (quote left)) >> '(org-agenda-files (quote ("~/Documents/OrgMode.org"))) >> '(save-place t nil (saveplace)) >> '(size-indication-mode t) >> '(text-mode-hook (quote (turn-on-auto-fill = text-mode-hook-identify))) >> '(truncate-lines t)) >> (custom-set-faces >> ;; custom-set-faces was added by Custom. >> ;; If you edit it by hand, you could mess it up, so be careful. >> ;; Your init file should contain only one such instance. >> ;; If there is more than one, they won't work right. >> '(default ((t (:inherit nil :stipple nil :background "White" = :foreground "Black" :inverse-video nil :box nil :strike-through nil = :overline nil :underline nil :slant normal :weight normal :height 180 = :width normal :foundry "apple" :family "Monaco")))) >> '(set-face-attribute (quote default) nil :height)) >>=20 >> (setenv "PATH" (concat (getenv "PATH") ":/usr/texbin")) >> (setq exec-path (append exec-path '("/usr/texbin"))) >>=20 >> (defun mapcdi-org-latex-headline-function (todo todo-type priority = text tags) >> "The docstring of my function." >> (concat >> (and todo (format "{}" todo)) >> (and priority (format "{} " )) >> (and text (format "{\\vspace{-\\baselineskip}}" )) >> (and tags >> (format "\\hfill{}\\textit{}" (mapconcat 'identity tags = ":"))))) >>=20 >> <2013-09-02_203154.png> >=20 --Apple-Mail=_947CCBE6-48A4-4419-BF81-2564D8E6BE80 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=windows-1252 test-file.org) = working setup, as a reminder:

;; change path to point to your org/lisp = directory
(add-to-list 'load-path = "~/.elisp/org.git/lisp/")

(setq = org-export-allow-bind-keywords t)

(defun = mapcdi-org-latex-headline-function (todo todo-type priority text = tags)
 "The docstring of my = function."
 (concat
  (and todo (format = "{}" todo))
  (and priority (format "{} " = ))
  (and text (format "{\\vspace{-\\baselineskip}}" = ))
  (and tags
      =  (format "\\hfill{}\\textit{}" (mapconcat = 'identity tags = ":")))))



Thanks,

=
Mark




El 03/09/2013, a las 09:16, mapcdi@me.com escribi=F3:

http://orgmode.org/org.h= tml#Installation


and now I = have 8.0.7. I compiled with your .emacs/.org example files, except = I needed to add:

(setenv "PATH" (concat = (getenv "PATH") ":/usr/texbin"))
    (setq exec-path = (append exec-path '("/usr/texbin")))

or = it wouldn't compile the PDF,
and there's the output: = success!


So, I will start = tinkering myself with some settings like:

By the way, do you know how I could eliminate my needed = line,  in my .emacs:
(setenv "PATH" (concat (getenv = "PATH") ":/usr/texbin"))
    (setq exec-path (append = exec-path '("/usr/texbin")))
by way of setting things to a = default setting so I don't need to update my path every time via = .emacs.


Thanks!

Mark



El = 03/09/2013, a las 03:32, John Hendy <jw.hendy@gmail.com> = escribi=F3:




On Mon, Sep 2, 2013 at 4:53 PM, <mapcdi@me.com> wrote:
<OrgMode_LaTeX_output_PDF_Ima= geCapture.png>



After I compile:  C-c    C-e    d (=85 to = open PDF file).
It asks:
'Allow BIND values in this buffer? (yes or no) = '
I answer 'yes' and the PDF is opened. I have attached the = resulting PDF screen capture.
Thanks.


What is your orgmode version = (paste the output of `M-x org-version`)? I decided to just give a whirl = with a minimal config and I don't think that Org 8+ asks for allowing = bind keywords anymore, or at least it isn't asking me with 8.0.7. =46rom = my tinkering, it looks like it ignores them or you need to explictly = allow them:

M-x customize-variable RET = org-export-allow-bind-keywords RET

Hide = Org Export Allow Bind Keywords: Toggle  on = (non-nil)
    State : CHANGED outside = Customize.
   Non-nil means BIND keywords can define local variable = values. Hide
   This is a potential security risk, = which is why the default value
   is nil.  You = can also allow them through local buffer variables.

I could be wrong, but the "toggle" button (vs. = stating possible values) implies that it's either on or = off.

Actually, in just searching now, it seems = that this is, indeed, the case since 8.0.3:


In any case, I am = now using this for my minimal config and it works successfully:

#+begin_src

;; change path = to point to your org/lisp directory
(add-to-list = 'load-path "~/.elisp/org.git/lisp/")

(setq = org-export-allow-bind-keywords t)

(defun mapcdi-org-latex-headline-function (todo = todo-type priority text tags)
 "The docstring of my = function."
 (concat
  (and todo (format = "{}" todo))
  (and priority (format "{} " ))
  (and text = (format "{\\vspace{-\\baselineskip}}" ))
  (and = tags
       (format "\\hfill{}\\textit{}" (mapconcat = 'identity tags ":")))))

#+end_src
 
And this = is the file I'm using (I removed anything non-essential to eliminate = other possible = causes):

#+begin_src

#+options: num:nil
#+bind: = org-latex-format-headline-function = mapcdi-org-latex-headline-function



* headline 1

blah blah = blah.

* headline 2

blah blah = blah

* headline 3

A = couple of separate paragraphs to see how far apart two paragraphs would = be
normally. We'll add enough to line break just to make it = interesting.

A couple of separate paragraphs to = see how far apart two paragraphs would be
normally. We'll add = enough to line break just to make it interesting.
=

#+end_src


I attached a screenshot of the = result!


Let me know if that = helps,
John



My test-file, OrgMode.org:

#+TITLE: =     My file is OrgMode.org
#+AUTHOR:   =  
#+EMAIL:     
#+DATE:     =  
#+DESCRIPTION:
#+KEYWORDS:
#+LANGUAGE= :  en
#+BIND: org-latex-format-headline-function = mapcdi-org-latex-headline-function
#+OPTIONS:   H:3 = num:nil toc:t \n:nil @:t ::t |:t ^:t 
#+OPTIONS:   -:t f:t *:t <:t tasks:nil
#+OPTIONS: =   pri:nil tags:not-in-toc
#+OPTIONS:   TeX:t LaTeX:t = skip:nil d:nil todo:t 
#+INFOJS_OPT: view:nil toc:nil = ltoc:t mouse:underline buttons:0 path:http://orgmode.org/org-info.js
#+EXPORT_SELECT_TAGS: export
#+EXPORT_EXCLUDE_TAGS: = noexport
#+LINK_UP: =   
#+LINK_HOME: 
#+XSLT:

=
* TODO headline 1 =       = :test:

blah blah = blah.

* headline = 2

blah blah blah

* = headline 3

A couple of separate paragraphs to = see how far apart two paragraphs would be
normally. We'll add enough to line break just to make it = interesting.

A couple of separate paragraphs to = see how far apart two paragraphs would be
normally. We'll add = enough to line break just to make it interesting.
=




____________________________________________________________________
My .emacs = file

(custom-set-variables
 ;; custom-set-variables was added by = Custom.
 ;; If you edit it by hand, you could mess it up, = so be careful.
 ;; Your init file should contain only one = such instance.
 ;; If there is more than one, they won't = work right.
 '(adaptive-fill-mode nil)
 '(blink-cursor-mode = nil)
 '(column-number-mode = t)
 '(current-language-environment = "Spanish")
 '(debug-on-error t)
 '(debug-on-quit t)
 '(display-battery-mode = t)
 '(display-time-mode t)
 '(fill-column = 56)
 '(left-margin = 0)
 '(ns-alternate-modifier (quote meta))
 '(ns-command-modifier (quote = super))
 '(ns-function-modifier (quote = none))
 '(ns-right-alternate-modifier (quote = none))
 '(ns-right-command-modifier (quote = left))
 '(org-agenda-files (quote ("~/Documents/OrgMode.org")))
 '(save-place t nil = (saveplace))
 '(size-indication-mode = t)
 '(text-mode-hook (quote (turn-on-auto-fill = text-mode-hook-identify)))
 '(truncate-lines = t))
(custom-set-faces
 ;; custom-set-faces was = added by Custom.
 ;; If you edit it by hand, you could = mess it up, so be careful.
 ;; Your init file should = contain only one such instance.
 ;; If there is more than one, they won't work = right.
 '(default ((t (:inherit nil :stipple nil = :background "White" :foreground "Black" :inverse-video nil :box nil = :strike-through nil :overline nil :underline nil :slant normal :weight = normal :height 180 :width normal :foundry "apple" :family = "Monaco"))))
 '(set-face-attribute (quote default) nil = :height))

(setenv "PATH" (concat (getenv = "PATH") ":/usr/texbin"))
    (setq exec-path (append = exec-path '("/usr/texbin")))

(defun = mapcdi-org-latex-headline-function (todo todo-type priority text = tags)
 "The docstring of my = function."
 (concat
  (and todo (format = "{}" todo))
  (and priority (format "{} " ))
  (and text = (format "{\\vspace{-\\baselineskip}}" ))
  (and = tags
       (format = "\\hfill{}\\textit{}" (mapconcat 'identity tags ":")))))

= <2013-09-02_203154.png>

= --Apple-Mail=_947CCBE6-48A4-4419-BF81-2564D8E6BE80--