[O] Inheriting Properties
Hi, I'm a new org-mode user and I'm just starting to use it in a real way. One feature that seems to be missing is the ability to specify properties on a parent-node that are inherited by the children, but is not applied to the parent itself. An example of where you might need this is: * Servers :PROPERTIES: :COLUMNS: %25ITEM %ip :END ** foo.example.com :PROPERTIES: :ip:x.x.x.x :END ** bar.example.com :PROPERTIES: :ip:x.x.x.x :END If there was a way to apply the root properties to the children but not the parent itself, then column mode would work as expected but would not apply the columns specification to the "Servers" node where it is not relevant. As it is now, each child-entry needs it's own column specification.
Re: [O] Timesheet from clocking data
Hi Bernt, On Fri, Apr 22, 2011 at 03:25, Bernt Hansen wrote: > Aankhen writes: > >> Greetings, >> >> Given an Org file with clocking data, is there a way to generate a >> timesheet? This would complement the clock table by focusing on the >> timings rather than the headings. >> >> As I haven’t come across anything like this as yet, I’ll try to give >> an example (manually-created) to show what I mean, in case someone >> more familiar with Org can tell me something about it: >> >> ,[ Org tree ] >> | * Foo >> | :CLOCK: >> | CLOCK: [2011-04-19 Tue 18:50]--[2011-04-19 Tue 20:30] => 1:40 >> | CLOCK: [2011-04-18 Mon 20:15]--[2011-04-18 Mon 21:00] => 0:45 >> | CLOCK: [2011-04-21 Thu 01:03]--[2011-04-21 Thu 02:03] => 1:00 >> | :END: >> | CLOCK: [2011-04-19 Tue 12:30]--[2011-04-19 Tue 18:06] => 5:36 >> | >> | >> | *** Bar >> | :CLOCK: >> | CLOCK: [2011-04-19 Tue 18:06]--[2011-04-19 Tue 18:50] => 0:44 >> | CLOCK: [2011-04-22 Fri 01:00]--[2011-04-22 Fri 01:05] => 0:05 >> | :END: >> | >> | *** Baz >> | :CLOCK: >> | CLOCK: [2011-04-21 Thu 03:10]--[2011-04-21 Thu 04:00] => 0:50 >> | :END: >> ` >> >> [snip] > > Hi Aankhen, > > There is no functionality that produces the table in your timesheet > example that I am aware of. Personally I use the agenda view with log > mode enabled for clock lines and limited to some interesting tags and a > summary report with C-u R. I then manually transfer the data to another > system for timesheet reporting. I just visit each day in the timesheet > range to get the details I want. > > You can generate daily reports with something like this > > #+BEGIN: clocktable :maxlevel 2 :scope agenda :fileskip0 t :step day :block > thisweek > #+END: > > which gives a separate table per day but it doesn't include the time > details. I see, thank you for the answer. I might end up using a second system for this too, this time. Maybe I’ll try writing something to produce these tables in a few days, by hacking together bits from the clock table. Aankhen
[O] [PATCH] alt for inline thumbnail
Hi, Here's a patch to add the following syntax for image link in html exports: [[file:hires.jpg][file:thumb.jpg::my description]] "my description" will be used for the alt attribute of the thumbnail. >From 53a6b03ad51ed4e05053a220872c2de72f2d254c Mon Sep 17 00:00:00 2001 From: Manuel Giraud Date: Wed, 20 Apr 2011 16:04:17 +0200 Subject: [PATCH 2/2] * org-html.el (org-html-handle-links): use fragment part of an image description as the alt --- doc/org.texi |4 ++- lisp/org-html.el | 92 +++--- 2 files changed, 49 insertions(+), 47 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index 8ca4426..3ff862e 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -9771,9 +9771,11 @@ image will activate the link. For example, to include a thumbnail that will link to a high resolution version of the image, you could use: @example -[[file:highres.jpg][file:thumb.jpg]] +[[file:highres.jpg][file:thumb.jpg::my cat hunting a mosquito]] @end example +The part after the double colon is used to make the @code{alt} attribute. + If you need to add attributes to an inlined image, use a @code{#+ATTR_HTML}. In the example below we specify the @code{alt} and @code{title} attributes to support text viewers and accessibility, and align it to the right. diff --git a/lisp/org-html.el b/lisp/org-html.el index 7a4564d..4a53f77 100644 --- a/lisp/org-html.el +++ b/lisp/org-html.el @@ -854,6 +854,14 @@ MAY-INLINE-P allows inlining it as an image." (org-export-html-format-desc desc) "") +(defun org-html-split-path-fragment (fullpath) + "Return a cons with car as the path and cdr as the fragment." + (save-match-data +(if (string-match "::\\(.*\\)" fullpath) + (cons (replace-match "" t nil fullpath) + (match-string 1 fullpath)) + (cons fullpath nil + (defun org-html-handle-links (line opt-plist) "Return LINE with markup of Org mode links. OPT-PLIST is the export options list." @@ -882,15 +890,17 @@ OPT-PLIST is the export options list." descp (and desc1 (not (equal desc1 desc2))) desc (or desc1 desc2)) ;; Make an image out of the description if that is so wanted - (when (and descp (org-file-image-p - desc org-export-html-inline-image-extensions)) - (save-match-data - (if (string-match "^file:" desc) - (setq desc (substring desc (match-end 0) - (setq desc (org-add-props - (concat "") - '(org-protected t + (let* ((components (org-html-split-path-fragment desc)) + (src (car components)) + (alt (cdr components))) + (when (and descp + (org-file-image-p src org-export-html-inline-image-extensions)) + (save-match-data + (if (string-match "^file:" src) + (setq src (substring src (match-end 0) + (setq desc (org-add-props + (concat "") + '(org-protected t) (cond ((equal type "internal") (let @@ -965,44 +975,34 @@ OPT-PLIST is the export options list." ((string= type "file") ;; FILE link (save-match-data - (let* - ((components - (if - (string-match "::\\(.*\\)" path) - (list - (replace-match "" t nil path) - (match-string 1 path)) - (list path nil))) - - ;;The proper path, without a fragment - (path-1 - (first components)) - - ;;The raw fragment - (fragment-0 - (second components)) - - ;;Check the fragment. If it can't be used as - ;;target fragment we'll pass nil instead. - (fragment-1 - (if - (and fragment-0 - (not (string-match "^[0-9]*$" fragment-0)) - (not (string-match "^\\*" fragment-0)) - (not (string-match "^/.*/$" fragment-0))) - (org-solidify-link-text - (org-link-unescape fragment-0)) - nil)) - (desc-2 - ;;Description minus "file:" and ".org" - (if (string-match "^file:" desc) - (let - ((desc-1 (replace-match "" t t desc))) - (if (string-match "\\.org$" desc-1) - (replace-match "" t t desc-1) - desc-1)) - desc))) + (let* ((components (org-html-split-path-fragment path)) + ;;The proper path, without a fragment + (path-1 (car components)) + + ;;The raw fragment + (fragment-0 (cdr components)) + + ;;Check the fragment. If it can't be used as + ;;target fragment we'll pass nil instead. + (fragment-1 + (if + (and fragment-0 + (not (string-match "^[0-9]*$" fragment-0)) + (not (string-match "^\\*" fragment-0)) + (not (string-match "^/.*/$" fragment-0))) + (org-solidify-link-text + (org-link-unescape fragment-0)) + nil)) + (desc-2 + ;;Description minus "file:" and ".org" + (if (string-match "^file:" desc) + (let + ((desc-1 (replace-match "" t t desc))) + (if (string-match "\\.org$" desc-1) + (replace-match "" t t desc-1) + desc-1)) + desc))) (setq rpl (if (and -- 1.7.3.5 -- Manuel Giraud
Re: [O] NEW auto dimension tables doesn\'t work in orgtbl Text mode
Is there any hook to customize different font for text orgtbl mode and different for the rest? Cannot find proper option in menu. Sebastian Szwarc
Re: [O] NEW auto dimension tables doesn\'t work in orgtbl Text mode
On 22.4.2011, at 12:03, Sebastian Szwarc wrote: > Is there any hook to customize different font for text orgtbl mode and > different for the rest? > Cannot find proper option in menu. You might want to try to configure the fonts org-table and org-formula. - Carsten
Re: [O] Inheriting Properties
Dustin Lacewell writes: > Hi, I'm a new org-mode user and I'm just starting to use it in a real > way. One feature that seems to be missing is the ability to specify > properties on a parent-node that are inherited by the children, but is > not applied to the parent itself. An example of where you might need > this is: > > * Servers >:PROPERTIES: >:COLUMNS: %25ITEM %ip >:END > ** foo.example.com >:PROPERTIES: >:ip:x.x.x.x >:END > ** bar.example.com >:PROPERTIES: >:ip:x.x.x.x >:END > > If there was a way to apply the root properties to the children but > not the parent itself, then column mode would work as expected but > would not apply the columns specification to the "Servers" node where > it is not relevant. As it is now, each child-entry needs it's own > column specification. Is there a practical reason you do not want the Servers heading included in the columns view? One advantage of including the heading is that, as your data grows, you can use that line to summarize the data in the subheadings: (info "(org) Column attributes") Best, Matt
Re: [O] Feature request: modify italic regexp list to include non-breaking space and other characters
On Thu, 21 Apr 2011 00:48:21 +0530 Aankhen wrote: > On Wed, Apr 20, 2011 at 20:34, wrote: > > Sample code: > > Using /a/’s and /b/’s, write add /x/ + 2. > > ^ ^ ^ ^ > > Right single quotation mark Non-breaking space > > > > Expected HTML export: > > Using a’s and b’s, write x + 2. > > > > Actual HTML export: > > Using /a/’s and /b/’s, write add /x/ + 2. > > Interestingly, the development version treats this differently, as it > considers all the text from the first slash to the last part of the > emphasis: > > , > | Using a/’s and /b/’s, write add /x + 2. > | > ` > > (This behaviour occurs in the original Org buffer as well, in case > anyone’s wondering. The exported HTML was just the easiest way to > show it.) Ouch. I hope the devs consider that to be a bug and fix it in the development version. > > > If it's not clear, the sample code uses the unicode character "right single > > character" instead of an apostrophe and "non-breaking space" instead of > > regular white space. > > > > It makes sense to use these characters this way, however, orgmode neither > > displays the italic expressions correctly nor exports them correctly. > > > > I believe older versions of orgmode worked in the expected way. > > > > How can I modify the regexp list? Bold characters are also affected. > > These two variables are used to configure the regexp: > > ,[ C-h v org-emphasis-alist RET ] > | org-emphasis-alist is a variable defined in `org.el'. > | Its value is (("*" bold "" "") > | ("/" italic "" "") > | ("_" underline "" "") > | ("=" org-code "" "" verbatim) > | ("~" org-verbatim "" "" verbatim) > | ("+" > | (:strike-through t) > | "" "")) > | > | > | Documentation: > | Special syntax for emphasized text. > | Text starting and ending with a special character will be emphasized, for > | example *bold*, _underlined_ and /italic/. This variable sets the marker > | characters, the face to be used by font-lock for highlighting in Org-mode > | Emacs buffers, and the HTML tags to be used for this. > | For LaTeX export, see the variable `org-export-latex-emphasis-alist'. > | For DocBook export, see the variable `org-export-docbook-emphasis-alist'. > | Use customize to modify this, or restart Emacs after changing it. > | > | You can customize this variable. > ` > > ,[ C-h v org-emphasis-regexp-components RET ] > | org-emphasis-regexp-components is a variable defined in `org.el'. > | Its value is (" ('\"{" "- .,:!?;'\")}\\" " > \n,\"'" "." 1) > | > | > | Documentation: > | Components used to build the regular expression for emphasis. > | This is a list with five entries. Terminology: In an emphasis string > | like " *strong word* ", we call the initial space PREMATCH, the final > | space POSTMATCH, the stars MARKERS, "s" and "d" are BORDER characters > | and "trong wor" is the body. The different components in this variable > | specify what is allowed/forbidden in each part: > | > | pre Chars allowed as prematch. Beginning of line will be > allowed too. > | post Chars allowed as postmatch. End of line will be allowed too. > | border The chars *forbidden* as border characters. > | body-regexp A regexp like "." to match a body character. Don't use > | non-shy groups here, and don't allow newline here. > | newline The maximum number of newlines allowed in an emphasis exp. > | > | Use customize to modify this, or restart Emacs after changing it. > | > | You can customize this variable. > | > | [back] > ` Thanks! > > I’d say that ‘pre’/‘post’ should really contain [[:space:]], but then > Org’s syntax table seems to treat the non-breaking space as > punctuation, so that wouldn’t help. You could try adding the > character itself to both of those categories for a fix. You’ll need > to restart Emacs afterwards (unless you used the Customize interface) > so that ‘org-emph-re’ is updated accordingly. > > > Using 7.4. > > This little problem aside, you might want to upgrade (if not to the > development version, at least to 7.5). > > Aankhen Oh I'm using nt emacs. I believe that's the latest they have out but will check again.
Re: [O] [BUG] ORG-LIST-END-MARKER within table.el table
Hello, Jambunathan K writes: > Export the following fragment to html > > * Another Table.el Table with Spanning > > +--+--+ > | Header 1 | Header 2 | > +--+--+ > | R1 C1-2 | > +--+--+ > | R2 C1| R2-3 C2 | > + +--+ > | | | > +--+--+ > > > Examine the temporary buffer that is emitted by > `org-export-preprocess-string'. Note that there is a ORG-LIST-END-MARKER > within the table.el table. > > > * Another Table.el Table with Spanning > > +--+--+ > | Header 1 | Header 2 | > +--+--+ > | R1 C1-2 | > +--+--+ > | R2 C1| R2-3 C2 | > + +--+ > ORG-LIST-END-MARKER > +--+--+ This is because + +--+ is recognized as a list item. But this case shouldn't happen. If you span "R2 C1" cell vertically, you get +--+--+ | Header 1 | Header 2 | +--+--+ | R1 C1-2 | +--+--+ | R2 C1| R2-3 C2 | | +--+ | | | +--+--+ instead, which is correct. Did you edit table by hand? Regards, -- Nicolas Goaziou
[O] Tools for working with Zotero and OrgMode
Hi, 1) Zotero-BibLaTeXToClipBoard-Firefox-module I just started a new module for firefox, allowing one user to copy in the clipboard bibtex elements for the current selection inside Zotero. You just have to paste it to your bibtex file. https://github.com/bjonnh/Zotero-BibLaTeXToClipBoard-Firefox-module You would need this also as this module is based on this translator: https://code.google.com/p/zotero-biblatex-export/ 2) Zotero biblatex citation export This should be inserted shortly in the zotero-biblatex-export repo. But you can find it there for the moment : http://www.bjonnh.net/BibLaTeX-cite.js You just have to copy this one and the previous one (from the google repo) inside your Zotero translators directory. Using this and configuring Zotero to use it, I'm able to drag and drop from Zotero to my Org document (or LaTeX) directly (it inserts \cite{citationkey}) Hope it can help some of you. Jonathan signature.asc Description: OpenPGP digital signature
Re: [O] [PATCH] org-bibtex.el --- convert between Org headings and bibtex entries
Matt Lundin writes: > Hi Eric, > > "Eric Schulte" writes: > >> In an attempt to organize my reading notes, I've written the following >> tool which allows both for exporting Org-mode headlines with bibtex >> meta-data to bibtex entries, and for reading existing bibtex entries >> into Org-mode headings. >> >> One nice feature of these functions is the ability to check that all >> required fields are present in a given headline based on the bibtex type >> (e.g., :article, :inproceedings), and prompt for missing fields. >> >> See the top of the elisp file for more usage information. >> https://github.com/eschulte/org-bibtex/blob/master/org-bibtex.el > > Thanks for announcing this! One note: I believe the name conflicts with > a core org-module (org-bibtex.el), which is used to store and open > bibtex links. > As one possible solution to this name conflict, I've folded my org-bibtex.el into the existing org-bibtex.el in the Org-mode core. The attached patch performs this integration adding the functionality in my version of org-bibtex.el into the Org-mode core. Does this seem like an appropriate addition? Thanks -- Eric (p.s. created with "git format-patch" and can be applied using "git am") >From d0ec36c11152c342584d5a2145871ebb2b195127 Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Fri, 22 Apr 2011 06:19:30 -0600 Subject: [PATCH] org-bibtex: translating between Org-mode headings and Bibtex entries * lisp/org-bibtex.el: Updating Copyright dates, author information, commentary and history notes. (org-bibtex-types): List of bibtex types with descriptions and required and optional fields. (org-bibtex-fields): List of bibtex fields with descriptions. (*org-bibtex-entries*): Special variable to hold parsed bibtex entries. (org-bibtex-autogen-keys): Custom variable controlling whether bibtex keys are automatically generated (org-bibtex-prefix): Custom variable allowing use of optional prefix for bibtex properties in Org-mode headlines. (org-bibtex-get): Helper function for accessing bibtex elements of a property list. (org-bibtex-put): Helper function for inserting bibtex element into a property list. (org-bibtex-headline): Return a bibtex entry of the given headline as a string. (org-bibtex-ask): Prompt the user to fill in the value of a bibtex field. (org-bibtex-autokey): Generate a bibtex key for the current headline. (org-bibtex-fleshout): Fill in missing bibtex properties of the current headline. (org-bibtex): Export the current Org-mode buffer to a bibtex buffer. (org-bibtex-check): Check that all bibtex properties are present in the current headline. (org-bibtex-check-all): Check all headlines in the current buffer. (org-bibtex-create): Create a new bibtex headline at the current level. (org-bibtex-read): Read the current bibtex entry from a bibtex file. (org-bibtex-write): Write the most recently read bibtex entry into an Org-mode file. --- lisp/org-bibtex.el | 317 +-- 1 files changed, 304 insertions(+), 13 deletions(-) diff --git a/lisp/org-bibtex.el b/lisp/org-bibtex.el index b7b7416..5667a4d 100644 --- a/lisp/org-bibtex.el +++ b/lisp/org-bibtex.el @@ -1,9 +1,10 @@ ;;; org-bibtex.el --- Org links to BibTeX entries ;; -;; Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. ;; ;; Author: Bastien Guerry ;; Carsten Dominik +;; Eric Schulte ;; Keywords: org, wp, remember ;; Version: 7.5 ;; @@ -66,12 +67,30 @@ ;; = ;; * READ <== [point here] ;; -;; [[file:/file.bib::dolev83][Dolev & Yao 1983: security of public key protocols]] +;; [[file:file.bib::dolev83][Dolev & Yao 1983: security of public key protocols]] ;; ;; Danny Dolev and Andrew C. Yao (1983): On the security of public-key protocols ;; In IEEE Transaction on Information Theory, 198--208. ;; = ;; +;; Additionally, the following functions are now available for storing +;; bibtex entries within Org-mode documents. +;; +;; - Run `org-bibtex' to export the current file to a .bib. +;; +;; - Run `org-bibtex-check' or `org-bibtex-check-all' to check and +;; fill in missing field of either the current, or all headlines +;; +;; - Run `org-bibtex-create' to add a bibtex entry +;; +;; - Use `org-bibtex-read' to read a bibtex entry after `point' or in +;; the active region, then call `org-bibtex-write' in a .org file to +;; insert a heading for the read bibtex entry +;; +;; - All Bibtex information is taken from the document compiled by +;; Andrew Roberts from the Bibtex manual, available at +;; http://www.andy-roberts.net/misc/latex/sessions/bibtex/bibentries.pdf +;; ;;; History: ;; ;; The link creation part has been part of Org-mode for a long time. @@ -80,
Re: [O] Patch for org-babel manual node
Hi Robert, I've just applied this patch. Thanks! -- Eric Robert Goldman writes: > On 4/21/11 Apr 21 -3:56 PM, Eric Schulte wrote: >> Patch appears to be missing, could you resend? > > Hope this will go through better > > LMK if you don't get it. >> >> Thanks -- Eric >> >> "Robert P. Goldman" writes: >> >>> There was a bug in an example of argument passing in the org-babel >>> part of the manual. Fixed in the following patch. >>> >>> >> > > -- Eric Schulte http://cs.unm.edu/~eschulte/
Re: [O] Title page in latex export
At Fri, 04 Mar 2011 10:45:08 -0500, Nick Dokos wrote: > > Suvayu Ali wrote: > > > > > I am trying to write my thesis as per my university style. It requires > > I use the \title{Thesis title} command before the > > > > \begin{document} > > ... > > \end{document} > > > > Is there any way to do that? Thanks for any thoughts. > > > > This is really a bug in your university's style. Lamport (p.21 of the > second edition) says: > > The \maketitle command comes after the \begin{document}, usually > before any other text. The \title, \author, and \date commands can > come *anywhere* before the \maketitle. > > [Emphasis added] \title etc. does not have to be in the > preamble. However, there are many styles out there that restrict the > placement of these macros to the preamble, just as your university's > style does (they probably cribbed from each other :-) ), so applying > Lawrence's patch is probably the best long term solution for org. > > Nick Hi all, I hate to bring this up again, but this problem is still not sufficiently fixed. As Nick pointed out, different packages give error messages depending on where the \title, \author,... tags are located in the document. Luck has it, that the revtex4-1 package (which is used as the default style for the American Physical Society's journals) chokes when these tags are _outside_ the document body (i.e. in the preamble). This is actually why the OP experienced problems in the first place, as I submitted a patch to move them there a couple of months ago (http://thread.gmane.org/gmane.emacs.orgmode/34208). I just noticed yesterday that the patch has been undone. As this will not be the last time this issue comes up (especially due to the increasing popularity of org-mode), I think it would be worthwhile to do it right and introduce the possibility to customize the placement of the title tags. Two possibilities came to my mind: - customization on a per class basis This would be the most logical step, but I think that the way configuration of latex classes is handled in org speaks against that (as org-export-latex-classes only concerns the preamble, but not the document body) - customization on a per file basis by setting options I think this would be a feasible alternative from the usability point of view. At the same time I have to admit that I have no clue if it is a complicated matter to introduce new options in org, a quick look through the code didn't give me any inside. What do you all think? Cheers, Sebastian
Re: [O] [PATCH] org-bibtex.el --- convert between Org headings and bibtex entries
Hi Eric, "Eric Schulte" writes: > Matt Lundin writes: > >> "Eric Schulte" writes: >> >>> In an attempt to organize my reading notes, I've written the following >>> tool which allows both for exporting Org-mode headlines with bibtex >>> meta-data to bibtex entries, and for reading existing bibtex entries >>> into Org-mode headings. >>> >>> One nice feature of these functions is the ability to check that all >>> required fields are present in a given headline based on the bibtex type >>> (e.g., :article, :inproceedings), and prompt for missing fields. >>> >>> See the top of the elisp file for more usage information. >>> https://github.com/eschulte/org-bibtex/blob/master/org-bibtex.el >> >> Thanks for announcing this! One note: I believe the name conflicts with >> a core org-module (org-bibtex.el), which is used to store and open >> bibtex links. >> > > As one possible solution to this name conflict, I've folded my > org-bibtex.el into the existing org-bibtex.el in the Org-mode core. The > attached patch performs this integration adding the functionality in my > version of org-bibtex.el into the Org-mode core. > > Does this seem like an appropriate addition? +1 (or maybe +.75 -- see below) I think this could finally tempt me to move all my bibliographical data into org-mode files. (I've been keeping all my data in a central bibtex file and using reftex to generate links to citations.) My only reservation: modules such as org-bibtex.el, org-gnus.el, org-wl.el. (i.e., modules that contain the name of another emacs package) are conventionally reserved for hyperlinks. I have no idea whether this is a fixed convention, but we might want to ask Bastien or Carsten. I know the linking features would be untouched by the addition of this new functionality, but I wonder whether org <-> bibtex conversion occupies a distinct space. I can see now how the variables org-bibtex-types and org-bibtex-fields are a major improvement over bibtex-entry-field-alist, which contains a whole bunch of redundant field descriptions. This will make it much easier to configure my bibtex setup. Best, Matt
[O] particular capture method for a diet .. ?
Hi all, I am too fat. And I found in the past that the best way for me to loose weight is to log my eating habit every day and make sure that I eat between 1800 and 2200 kcal/day, no more, but also not less. I want to figure out a way how to create a custom capture template to keep track of my daily intake. The result should be a diary-style org file were every day would be filled with a table that features an updated total and an item list: TOTAL: 1965 kcal |apple | 80| |orange | 65| |energy drink | 300| ... etc (gnus: y u no tables ?) capturing would consist of two entries, item and specific caloric value, and these values would be inserted into a table that would automagically update its daily total. Every day a new table should be started. Is this possible ? And how ? Pointers, tips and snippets are greatly appreciated. Best, wzzl -- Stinky Wizzleteet thinks: Next Friday will not be your lucky day. As a matter of fact, you don't have a lucky day this year.
[O] where to edit latex default added packages ?
Hi all, I run emacs and latex on my nokia n900, but latex does not ome with a full complement of packages. I am looking to make the latex (esp. beamer) export from orgmode a little more barebone. Where/how do I tweak the packages that are added to the exported TeX header ? thanks, wzzl -- Stinky Wizzleteet thinks: Be free and open and breezy! Enjoy! Things won't get any better so get used to it.
Re: [O] where to edit latex default added packages ?
Stinky Wizzleteet writes: > Hi all, > > I run emacs and latex on my nokia n900, but latex does not ome with a > full complement of packages. > I am looking to make the latex (esp. beamer) export from orgmode a > little more barebone. > > Where/how do I tweak the packages that are added to the exported TeX > header ? You can configure the variable org-export-latex-classes. (info "(org) Header and sectioning") Best, Matt P.S. FWIW, I use easy debian to run a combination of emacs, LaTeX, git, etc. on the n900. Running debian in a chroot is a nice way to get access to the full panoply of tex packages without having to build them in scratchbox.
Re: [O] where to edit latex default added packages ?
Matt Lundin writes: > Stinky Wizzleteet writes: > >> Hi all, >> >> I run emacs and latex on my nokia n900, but latex does not ome with a >> full complement of packages. >> I am looking to make the latex (esp. beamer) export from orgmode a >> little more barebone. >> >> Where/how do I tweak the packages that are added to the exported TeX >> header ? > > You can configure the variable org-export-latex-classes. > > (info "(org) Header and sectioning") > > Best, > Matt > > P.S. FWIW, I use easy debian to run a combination of emacs, LaTeX, git, > etc. on the n900. Running debian in a chroot is a nice way to get access > to the full panoply of tex packages without having to build them in > scratchbox. > > Hi Matt, thanks for the tip, Also, I have briefly looked at easy debian and found that I valued integration above feature-completeness. But maybe I'll revisit that sentiment in the near future, thanks. best, wzzl -- Stinky Wizzleteet thinks: You will hear good news from one you thought unfriendly to you.
Re: [O] [BUG] ORG-LIST-END-MARKER within table.el table
Hello Nicolas > Hello, > > Jambunathan K writes: > >> Export the following fragment to html >> >> * Another Table.el Table with Spanning >> >> +--+--+ >> | Header 1 | Header 2 | >> +--+--+ >> | R1 C1-2 | >> +--+--+ >> | R2 C1| R2-3 C2 | >> + +--+ >> | | | >> +--+--+ >> >> >> Examine the temporary buffer that is emitted by >> `org-export-preprocess-string'. Note that there is a ORG-LIST-END-MARKER >> within the table.el table. >> >> >> * Another Table.el Table with Spanning >> >> +--+--+ >> | Header 1 | Header 2 | >> +--+--+ >> | R1 C1-2 | >> +--+--+ >> | R2 C1| R2-3 C2 | >> + +--+ >> ORG-LIST-END-MARKER >> +--+--+ > > This is because > > + +--+ > > is recognized as a list item. > > But this case shouldn't happen. If you span "R2 C1" cell vertically, you > get > > +--+--+ > | Header 1 | Header 2 | > +--+--+ > | R1 C1-2 | > +--+--+ > | R2 C1| R2-3 C2 | > | +--+ > | | | > +--+--+ > > instead, which is correct. Did you edit table by hand? It does look like I might have polluted a table.el table. (The table I presented has been with me for a few months now and I don't really recollect how I created it in the first place) I think I need to "fix" the buggy test case. Thanks a lot for pointing this out. Jambunathan K.
Re: [O] particular capture method for a diet .. ?
So I've been meaning to put something up on this in worg for a while. I've been dieting using orgmode, basic calorie tracking, and something resembling the ideas out of "The Hacker's Diet" for the last year (actually 2.5 years with a 1.5 year "break" in which I continued to weigh in mostly but didn't follow my calorie goals ;)) and have lost > 60 pounds so far (originally was 275, not all that's recorded in my files during the first few weeks of dieting, anyway at 210 now), going from morbidly obese to just overweight, and I'm still losing weight (soon enough, being a fat guy will be far behind me). Here's the org-babel generated gnuplot graphs to show it (regenerated and pushed to my site every morning): http://dustycloud.org/tmp/weight.png http://dustycloud.org/tmp/weight_month.png Here's a screenshot: http://dustycloud.org/tmp/org-diet2.png Roughly in the terrible amount of hacks that compose "org-diet" I've wrapped together these ideas/tools: - calorie tracking - recipe calorie calculation - weigh-in via org-capture - calorie "clocking" (clock out at the end of the day to verify you've got accurate numbers for that day) - habit tracking of whether you've met your calorie goals - weight graphing with 10 day moving averaging to remove some of the "noise" from a daily weigh in/out - bmi calculation - a really shitty calories-per-day-to-lose-to-meet-your-goals estimator It's really nothing complex, and mostly it's not software, just a methedology with a *slight* amount of poorly written software in elisp and org-babel, but the system works great. I planned after meeting my diet goals (hitting normal weight) that I'd release the whole thing (including my present diet file for reference) under GPLv3, document it in worg, and put my own diet file out there under CC0, but maybe I should do it sooner... problem is I don't have time presently while trying to work on http://mediagoblin.org on weekends to make a "proper" release, but I could at least bundle together everything you need to have a full system using my hacks for now if you want, with really terrible but usable documentation, without taking up too much time. :) Interested? I could probably throw together a terrible tarball this weekend if you want to use it and post it to the list. One thing that's clear from the diet I've collected: whenever I've followed the system, without fail, I've lost weight. When I've deviated I've stayed level or I've gained weight (the no-movement middle of the diet graph I linked to). Follow the system, use habit tracking and stuff, stick to your calorie goals (I shoot for a lower occasional-goal of 1300 calories and an absolute minimum goal of 1600 calories), and it *fucking works* without any support of the bullshit diet industry. I've heard a few people saying they have interest in the stuff I have so maybe I should just do that crappy release for now; better than nothing? Hopefully being useful while making embarassing admissions about my body, - cwebb Stinky Wizzleteet writes: > Hi all, > > I am too fat. > > And I found in the past that the best way for me to loose weight is to > log my eating habit every day and make sure that I eat between 1800 and > 2200 kcal/day, no more, but also not less. > > I want to figure out a way how to create a custom capture template to > keep track of my daily intake. > > The result should be a diary-style org file were every day would be > filled with a table that features an updated total and an item list: > > TOTAL: 1965 kcal > |apple | 80| > |orange | 65| > |energy drink | 300| > ... etc > > (gnus: y u no tables ?) > > capturing would consist of two entries, item and specific caloric > value, and these values would be inserted into a table that would > automagically update its daily total. > Every day a new table should be started. > > Is this possible ? And how ? > Pointers, tips and snippets are greatly appreciated. > > Best, > wzzl -- 𝓒𝓱𝓻𝓲𝓼𝓽𝓸𝓹𝓱𝓮𝓻 𝓐𝓵𝓵𝓪𝓷 𝓦𝓮𝓫𝓫𝓮𝓻
Re: [O] particular capture method for a diet .. ?
On Fri, Apr 22 2011, Christopher Allan Webber wrote: > So I've been meaning to put something up on this in worg for a while. > > I've been dieting using orgmode, basic calorie tracking, and something > resembling the ideas out of "The Hacker's Diet" for the last year > (actually 2.5 years with a 1.5 year "break" in which I continued to > weigh in mostly but didn't follow my calorie goals ;)) and have lost > > 60 pounds so far (originally was 275, not all that's recorded in my > files during the first few weeks of dieting, anyway at 210 now), going > from morbidly obese to just overweight, and I'm still losing weight > (soon enough, being a fat guy will be far behind me). Here's the > org-babel generated gnuplot graphs to show it (regenerated and pushed to > my site every morning): > > http://dustycloud.org/tmp/weight.png > http://dustycloud.org/tmp/weight_month.png Congratulations! I have been doing something similar for just over a year. Unfortunately, I made the mistake of using Simple Emacs Spreadsheets for my spreadsheets (I didn't really know about org-mode when I started). This means my spreadsheets can hold about a month's worth of data before they become too big to be usable. I switched my weight spreadsheet into org a while back so that I could use gnuplot to make graphs, but my food log is still in SES. > Here's a screenshot: > http://dustycloud.org/tmp/org-diet2.png > > Roughly in the terrible amount of hacks that compose "org-diet" I've > wrapped together these ideas/tools: > - calorie tracking > - recipe calorie calculation > - weigh-in via org-capture > - calorie "clocking" (clock out at the end of the day to verify you've >got accurate numbers for that day) > - habit tracking of whether you've met your calorie goals > - weight graphing with 10 day moving averaging to remove some of the >"noise" from a daily weigh in/out > - bmi calculation > - a really shitty calories-per-day-to-lose-to-meet-your-goals estimator > > It's really nothing complex, and mostly it's not software, just a > methedology with a *slight* amount of poorly written software in elisp > and org-babel, but the system works great. It sounds more feature complete than what I am currently using, and I actually *like* what I am using. > I planned after meeting my diet goals (hitting normal weight) that I'd > release the whole thing (including my present diet file for reference) > under GPLv3, document it in worg, and put my own diet file out there > under CC0, but maybe I should do it sooner... problem is I don't have > time presently while trying to work on http://mediagoblin.org on > weekends to make a "proper" release, but I could at least bundle > together everything you need to have a full system using my hacks for > now if you want, with really terrible but usable documentation, > without taking up too much time. :) > > Interested? I could probably throw together a terrible tarball this > weekend if you want to use it and post it to the list. > > One thing that's clear from the diet I've collected: whenever I've > followed the system, without fail, I've lost weight. When I've > deviated I've stayed level or I've gained weight (the no-movement > middle of the diet graph I linked to). Follow the system, use habit > tracking and stuff, stick to your calorie goals (I shoot for a lower > occasional-goal of 1300 calories and an absolute minimum goal of 1600 > calories), and it *fucking works* without any support of the bullshit > diet industry. > > I've heard a few people saying they have interest in the stuff I have > so maybe I should just do that crappy release for now; better than > nothing? I would at least be interested in taking a look at it. No promises, of course, but if I ended up using it, I would at least be willing to help you package (and possibly document) what you have. > Hopefully being useful while making embarassing admissions about my > body, > - cwebb There is nothing embarrassing about losing over 60 pounds. The mediagoblin.org thing looks interesting as well. Jason
Re: [O] NEW auto dimension tables doesn\\\'t work in orgtbl Text mode
Thanks for suggestion. Customization of org-mode is still bit tricky to me.. BTW what a surprize..before I get your response I watched video from your presentation about org-mode from 2008 :) Sebastian
[O] Bug: HTML blocks in macros called before lists break in 7.5
Sample code: - #+MACRO: start #+BEGIN_HTML\n \n#+END_HTML #+MACRO: end #+BEGIN_HTML\n \n#+END_HTML * Hello world {{{start}}} 1. Item 1 {{{end}}} --- Expected HTML export (valid HTML): -- Item 1 --- Actual HTML export (invalid HTML): --- Item 1 OK, so the example is a bit contrived. But that's basically the technique that I use to style lists. (It may not be the best but for complex START/END macros, using HTML blocks is the way to go.) Anyway, the above code worked fine in 7.4. Then I upgraded to 7.5 and I now have literally hundreds of these broken lists. Ideas? Where would the offending org code be?
Re: [O] Using orgmode to take "inline notes" for research
Rasmus writes: >> It is cool but doesn't play well with margins, as you have seen. I've >> given up on cool and use the following instead: > > I agree on the cool not being cool. However, I do wonder why you would > want to use /ordinary/ footnotes rather than something easily removable > such as fixmenotes, e.g. \fxnote[footnote]. The great thing is they are > removed in the `final' print (i.e. when `draft' is not specified). Sure, this would be a good thing for many to use. I don't require this because the documents I create have (or should have) no footnotes in the final version so any footnotes that are present are things I have to deal with! But thanks for pointing me to this alternative. >>> - Some of my notes are multi paragraphs, which I prefer non-indented >>> and separated by a line break rather than no line break and indented. >>> But when exported, multiple paragraphs just "stack up" with no line >>> break. Can I add this to your format? > > I use the following for empty lines. It is quite easy to adopt it > document wide and probably even inside certain environments. > >\newcommand*{\tomlinje}[0]{\\[\baselineskip] \setlength{\parskip}{0pt}} > > I didn't get whether you are asking for footnotes specifically, but if > this is the case you might be able to play around with > \setlength{\footparindent}{} and friends? Will do. Did not know about \footparindent and my searches did not find any reference to such! Thanks. -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.5 (release_7.5.183.g1997)
Re: [O] Show current task in taskbar
Nathan Neff writes: > Hello, > > I use wmii which is a minimalist tiling window manager. > It has a taskbar that can show text/icons, etc. > > I'd like to see my currently logged in task on the taskbar. > > The way I see it, I could either 1) poll emacs for the current task > or 2) have emacs run a cron job and output the current task to a file > or directly > set the taskbar > > Has anyone done something like this? I found the "External Programs" section > on this page: http://orgmode.org/worg/org-hacks.html but didn't find > anything directly. > > Thanks, > --Nate With ratpoison, I use either conky or dzen2 to write out a status line that is outside the window manager's control. one of the things I used to do is echo the contents of a file to that status bar and that file would include the clocking information. this clocking information was generated by the following elisp code: --8<---cut here---start->8--- (defun esf/org-clocking-info-to-file () (with-temp-file "~/tmp/clocking" ;; (message (org-clock-get-clock-string)) (if (org-clock-is-active) (insert (format "org: %d/%d min" (- (org-clock-get-clocked-time) org-clock-total-time) (org-clock-get-clocked-time)) ) ) ;;(org-clock-get-clock-string) ) ) (add-hook 'display-time-hook 'esf/org-clocking-info-to-file) --8<---cut here---end--->8--- I haven't used this in a while so cannot guarantee it will work with org 7.5, say, but it should. It requires you to have invoked (display-time) to hook into that display and obviously something to echo the contents of the file (~/tmp/clocking in above) into your wmii status bar. HTH, eric -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.5 (release_7.5.183.g1997)
Re: [O] [BUG][babel] ":result output table" doesn't work for python code blocks
"Eric Schulte" writes: > Eric S Fraga writes: > >> "Eric Schulte" writes: >> >> [...] >> >>> That said, I agree that in examples like yours above the returned value >>> should be a table given that the ":results table" is explicitly stated. >>> I've just pushed up a patch after which the following is possible. >> >> Eric, >> >> It would appear that this change you've made is only for python)? Is >> there any chance of having the same for octave, please? But only if it >> is easy to do as =:results output raw= with carefully formatted output >> does the job for me for the moment! >> > > Hi Eric, > > I do not have a local copy of octave, so I'm less confident making > changes to that file, but the attached patch attempts to make the same > changes in ob-octave which were made in ob-python. > > Could you please test this patch for both external and session based > evaluation and let me know if it works (I'm more hopeful that the > external evaluation will work as expected than the session > evaluation). Eric, thanks for this. I haven't tried the session based evaluation but the external one, unfortunately, doesn't work as I would expect. In the following, I would expect both source code blocks to give me the same output with the first, value based, being the correct output. --8<---cut here---start->8--- #+srcname: valueresult #+begin_src octave :results value table :cache yes values = []; for i=1:15 values(end+1,:) = [i, i^3]; endfor ans = values #+end_src #+results[7a87a711b7814ecf23ec5d3741a5fec33e44]: valueresult | 1 |1 | | 2 |8 | | 3 | 27 | | 4 | 64 | | 5 | 125 | | 6 | 216 | | 7 | 343 | | 8 | 512 | | 9 | 729 | | 10 | 1000 | | 11 | 1331 | | 12 | 1728 | | 13 | 2197 | | 14 | 2744 | | 15 | 3375 | #+srcname: outputresult #+begin_src octave :results output table :cache yes values = []; for i=1:15 values(end+1,:) = [i, i^3]; endfor disp(values) #+end_src #+results[3104573dcf8ec30de1a26aae7051a9e8fce6a92a]: outputresult | 1 1 | | 2 8 | | 3 27 | | 4 64 | | 5125 | | 6216 | | 7343 | | 8512 | | 9729 | | 10 1000 | | 11 1331 | | 12 1728 | | 13 2197 | | 14 2744 | | 15 3375 | --8<---cut here---end--->8--- Thanks, eric -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.5 (release_7.5.183.g1997.dirty)
Re: [O] [PATCH] org-bibtex.el --- convert between Org headings and bibtex entries
Matt Lundin writes: > "Eric Schulte" writes: >> As one possible solution to this name conflict, I've folded my >> org-bibtex.el into the existing org-bibtex.el in the Org-mode core. The >> attached patch performs this integration adding the functionality in my >> version of org-bibtex.el into the Org-mode core. >> >> Does this seem like an appropriate addition? > > +1 (or maybe +.75 -- see below) > > I think this could finally tempt me to move all my bibliographical data > into org-mode files. (I've been keeping all my data in a central bibtex > file and using reftex to generate links to citations.) I've been testing the patch and have a few comments. 1. The prompt for the completing-read on line 440 is missing a space. It shows "Type:" rather than "Type: ". 2. In addition, since the symbols in org-bibtex-types are keywords, the completions are in the form ":article", ":book", etc. Might I ask why everything is org-bibtex-type is a keyword? Could we use strings or plain symbols instead? (Note: I haven't read the code carefully enough to see if there is a reason.) 3. The tooltip/help pop-up for org-bibtex-create takes up half a frame. Thanks, Matt
Re: [O] particular capture method for a diet .. ?
Christopher Allan Webber writes: Wow, really, that's awesome and inspring. Congratulations ! I think the hacker's diet is the most useful thing to come out of autodesk. The first time I lost some serious weight was when I followed the hacker's diet in 2001, I used his palm III app for that. I've gained weight since the birth of my son and the start of my company and I want to curb it before it gets out of hand. I cap the caloric deficit at a 500 kcal deficit per day, because for me and my genetic background of overweight family this is probably not a diet but a lifestyle and I understood that at higher deficits ones metabolism is trying to adapt, trying to defeat the dieting purpose. (citation needed) -I cannot provide proof nor reference to this statement- Your approach is *exactly* what I was meaning to eventually throw together. I would love to take a look at your code, as a total noob I may be able to hack a workable system for myself -eventually, but help maintaining will be possible only on the long term. Once I've mastered lisp and org. However, as I am not the only one interested in your system you might want to consider dumping it loosely unorganized on github. but mailing us a tar package would be cool too. thx ! wzzl > So I've been meaning to put something up on this in worg for a while. > > I've been dieting using orgmode, basic calorie tracking, and something > resembling the ideas out of "The Hacker's Diet" for the last year > (actually 2.5 years with a 1.5 year "break" in which I continued to > weigh in mostly but didn't follow my calorie goals ;)) and have lost > > 60 pounds so far (originally was 275, not all that's recorded in my > files during the first few weeks of dieting, anyway at 210 now), going > from morbidly obese to just overweight, and I'm still losing weight > (soon enough, being a fat guy will be far behind me). Here's the > org-babel generated gnuplot graphs to show it (regenerated and pushed to > my site every morning): > > http://dustycloud.org/tmp/weight.png > http://dustycloud.org/tmp/weight_month.png > > Here's a screenshot: > http://dustycloud.org/tmp/org-diet2.png > > Roughly in the terrible amount of hacks that compose "org-diet" I've > wrapped together these ideas/tools: > - calorie tracking > - recipe calorie calculation > - weigh-in via org-capture > - calorie "clocking" (clock out at the end of the day to verify you've >got accurate numbers for that day) > - habit tracking of whether you've met your calorie goals > - weight graphing with 10 day moving averaging to remove some of the >"noise" from a daily weigh in/out > - bmi calculation > - a really shitty calories-per-day-to-lose-to-meet-your-goals estimator > > It's really nothing complex, and mostly it's not software, just a > methedology with a *slight* amount of poorly written software in elisp > and org-babel, but the system works great. > > I planned after meeting my diet goals (hitting normal weight) that I'd > release the whole thing (including my present diet file for reference) > under GPLv3, document it in worg, and put my own diet file out there > under CC0, but maybe I should do it sooner... problem is I don't have > time presently while trying to work on http://mediagoblin.org on > weekends to make a "proper" release, but I could at least bundle > together everything you need to have a full system using my hacks for > now if you want, with really terrible but usable documentation, without > taking up too much time. :) > > Interested? I could probably throw together a terrible tarball this > weekend if you want to use it and post it to the list. > > One thing that's clear from the diet I've collected: whenever I've > followed the system, without fail, I've lost weight. When I've deviated > I've stayed level or I've gained weight (the no-movement middle of the > diet graph I linked to). Follow the system, use habit tracking and > stuff, stick to your calorie goals (I shoot for a lower occasional-goal > of 1300 calories and an absolute minimum goal of 1600 calories), and it > *fucking works* without any support of the bullshit diet industry. > > I've heard a few people saying they have interest in the stuff I have so > maybe I should just do that crappy release for now; better than nothing? > > Hopefully being useful while making embarassing admissions about my > body, > - cwebb > > Stinky Wizzleteet writes: > >> Hi all, >> >> I am too fat. >> >> And I found in the past that the best way for me to loose weight is to >> log my eating habit every day and make sure that I eat between 1800 and >> 2200 kcal/day, no more, but also not less. >> >> I want to figure out a way how to create a custom capture template to >> keep track of my daily intake. >> >> The result should be a diary-style org file were every day would be >> filled with a table that features an updated total and an item list: >> >> TOTAL: 1965 kcal >> |apple | 80| >> |orange |