emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Glyn Millington <glyn.millington@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: trying to write a guidebook for students using org , need help with formating
Date: Wed, 23 Oct 2013 23:15:24 +0100	[thread overview]
Message-ID: <87iownbpmr.fsf@nowhere.org> (raw)
In-Reply-To: CAOQHXPoA_Pjv7XmYF8r3LggEsvnYbs0YQXkD0DfzqzanrjUxMw@mail.gmail.com

Xebar Saram <zeltakc@gmail.com> writes:

> Glyn: thx alot for the example. That does work but then i really hate
> manually having to add the '-' at the start of each page and then also
> indenting each line, is there a solution for that?

My problem is that I know a little LaTeX and less lisp!  I would just do
this the hard way.  If I was driven to automate it slightly, then not
being aware of an org-mode solution I would use latex, like this.

1. Make a file, xebar-bullets.tex, which contains this latex snippet

\begin{itemize}
\item Start typing here ....
\item This is the next item you can make these lines as long as you like!!
\item
\item
\item
\item
\item
\item
\item
\item
\item
\item
\item
\item
\item
\item
\end{itemize} 

save it somewhere safe, where you store templates etc

2. Write a function in your .emacs or init.el file like this


(defun xebar-bullets ()
"This inserts the LaTeX \itemize environment into a document - LaTeX will
take care of the wrapping of each item for me"
(interactive)
(insert-file-contents "/home/xebar/templates/xebar-bullets.tex"))

Save this. Evaluate it.


3. Add a key-binding, again in .emacs or init.el, to call this where you
want it.  s-d is the Super key plus d, or pick another - again evaluate
it.

(add-hook 'org-mode-hook
          (lambda ()
            (local-set-key (kbd "s-d") 'xebar-bullets)))

Then when you want to add a list of instructions as in your sample doc,
just hit s-d and start typing at the first item.  You can make the lines
as long as you like, and when you export, LaTeX will deal with 'em!  If
you need more items, just add them in.

I've spelled this out because you said you didn't know about LaTeX -
forgive me if it is more info than you need. 

atb

Glyn

  reply	other threads:[~2013-10-23 22:17 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-22  7:55 trying to write a guidebook for students using org , need help with formating Xebar Saram
2013-10-22  8:16 ` Glyn Millington
2013-10-22  8:25 ` Eric Abrahamsen
2013-10-22  9:39 ` Suvayu Ali
2013-10-22 12:14   ` Xebar Saram
2013-10-23  1:00     ` Eric Abrahamsen
2013-10-23  6:11       ` Xebar Saram
2013-10-23  8:56         ` Eric Abrahamsen
2013-10-23 12:23           ` Xebar Saram
2013-10-23 13:41             ` Eric Abrahamsen
2013-10-23 14:23             ` Glyn Millington
2013-10-23 18:19               ` Xebar Saram
2013-10-23 22:15                 ` Glyn Millington [this message]
2013-10-24  5:37                 ` Eric Abrahamsen
2013-10-24 10:43                   ` Suvayu Ali
2013-10-24 14:53                     ` Xebar Saram
2013-10-27  6:49                       ` Xebar Saram
2013-10-23 13:32         ` Rick Frankel
2013-10-22 16:42 ` Rick Frankel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87iownbpmr.fsf@nowhere.org \
    --to=glyn.millington@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).