Hi Bastien,

On Sat, 29 Oct 2011 15:08:44 +0200
Bastien <b...@altern.org> wrote:

> Hi Suvayu,
> 
> Suvayu Ali <fatkasuvayu+li...@gmail.com> writes:
> 
> > org-exp.el:2155:(defun org-export-get-title-from-subtree ()
> 
> Can you instrument this function with edbug-defun and see what might 
> be wrong with it?
> 

Lines:
2170:        (looking-at org-todo-line-regexp)
2171:        (setq title (match-string 3))

I tried using edebug-defun on the above function. I see that it reads
the title _with the tags_ no matter what are in the export options.

With the attached minimal test file, and starting Emacs as:

$ emacs -Q -l ~/.emacs.d/minimal-org.el subtree-test.org

I could export the entire file to html correctly (meaning the subtree
with the noexport tag is exported correctly). But When exporting the
subtree to pdf the noexport tag is included in the presentation title.

> I tried this file:
> 
...
> 
> and exporting the subtree named "beamer :noexport" uses the correct
> title here, i.e. "beamertitle".
> 

Sorry I should have provided an example file in the first place. I am
not setting the EXPORT_TITLE property. The bug is the tags:nil option
is not respected whether it is present in the file header or it is set
by the EXPORT_OPTIONS property for the exported subtree. This is
puzzling since other export options (e.g. ^:{}) is respected
irrespective of whether it is present in the file header or the
EXPORT_OPTIONS property.

> So I can't reproduce this...
> 

I hope this clearly describes the bug.

-- 
Suvayu

Open source is the future. It sets us free.
#+TITLE:     Subtree export bug
#+AUTHOR:    Suvayu Ali
#+EMAIL:     
#+DATE:      2011-10-29 Fri
#+DESCRIPTION:
#+KEYWORDS:
#+LANGUAGE:  en
#+OPTIONS:   H:3 num:nil toc:t \n:nil @:t ::t |:t ^:{} -:t f:t *:t <:t
#+OPTIONS:   TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:nil
#+EXPORT_SELECT_TAGS: export
#+EXPORT_EXCLUDE_TAGS: noexport


* Top level header

Irrespective of whether I have =^:{}= in the subtree =EXPORT_OPTIONS=,
the subscript/superscript settings are respected. I was expecting the
same for =tags:nil=. Not only does that not happen, even setting the
option hs no effect on the exported title.

This text is not going to be exported to beamer.

** Subtree export tags in title bug                                :noexport:
   :PROPERTIES:
   :EXPORT_FILE_NAME: subtree-test.pdf
   :EXPORT_DATE: 29 Oct 2011
   :LaTeX_CLASS: beamer
   :LaTeX_CLASS_OPTIONS: [smaller]
   :BEAMER_FRAME_LEVEL: 1
   :EXPORT_AUTHOR: Suvayu Ali
   :EXPORT_OPTIONS: tags:nil
   :END:

*** Subscript/Superscript
+ Subscript/Superscript within braces: B^{0}_{s}
+ Subscript/Superscript without braces: B^0_s


*** Acknowledgements
+ Thanks to XYZ, Foo and Bar
% Created 2011-10-29 Sat 16:38
\documentclass[smaller]{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{fixltx2e}
\usepackage{graphicx}
\usepackage{longtable}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{soul}
\usepackage{textcomp}
\usepackage{marvosym}
\usepackage{wasysym}
\usepackage{latexsym}
\usepackage{amssymb}
\usepackage{hyperref}
\tolerance=1000
\providecommand{\alert}[1]{\textbf{#1}}

\title{Subtree export tags in title bug                            
\textbf{:noexport:}}
\author{Suvayu Ali}
\date{29 Oct 2011}
\hypersetup{
  pdfkeywords={},
  pdfsubject={},
  pdfcreator={Emacs Org-mode version 7.7}}

\begin{document}

\maketitle


\begin{frame}
\frametitle{Subscript/Superscript}
\label{sec-1}

\begin{itemize}
\item Subscript/Superscript within braces: B$^{0}$$_{s}$
\item Subscript/Superscript without braces: B\^{}0\_{}s
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Acknowledgements}
\label{sec-2}

\begin{itemize}
\item Thanks to XYZ, Foo and Bar
\end{itemize}
\end{frame}

\end{document}

Reply via email to