From: Carsten Dominik <dominik@science.uva.nl>
To: Mark Aufflick <mark-emacs@aufflick.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: org-mode and longlines-mode (especially tables)
Date: Mon, 26 Mar 2007 17:34:03 +0200 [thread overview]
Message-ID: <b3615d07343dd6bd2f65b0b22ae4e7cb@science.uva.nl> (raw)
In-Reply-To: <1242f34a0703241851s20a27113jad5fcc09c88b1f3a@mail.gmail.com>
Hmmmm, the other day I had a working version, but you are right, what I
posted does not work. I don't understand yet why - I'll be back about
this.
- Carsten
On Mar 25, 2007, at 3:51, Mark Aufflick wrote:
> Damn - defadvice is way cool! I do similar AOP-style things in Perl,
> but nothing that clean or simple.
>
> Having said that, it doesn't seem effective for me. It compiles fine
> (in my .emacs), but there is no change in functionality. I tried with
> org-mode 4.6.7 and then upgraded to .9. gnu emacs 22.0.94.1
>
> I'm not familiar with the calling syntax of defadvice, so I'll keep
> playing.
>
> Thanks very much for the code.
>
> Mark.
>
>
> On 3/23/07, Carsten Dominik <dominik@science.uva.nl> wrote:
>>
>> On Mar 19, 2007, at 13:46, Alan Dove wrote:
>>
>> > Hey, folks:
>> >
>> > I've also been using org-mode with longlines-mode, and had noticed
>> > that the two occasionally conflict. I've just developed workarounds
>> > for the bugs that affect me, mostly inserting extra carriage returns
>> > here and there to ensure the right line breaks for org-mode.
>> Carsten,
>> > if you have the option of minimizing these conflicts, that would be
>> > great.
>>
>> I think this is really really hard. Basically, I would have to change
>> all places where Org-mode inserts newlines that should be hard.
>>
>> Hmmm, maybe all newlines that org-mode inserts during internal
>> commands
>> should be hard?
>>
>> In this case, a brute-force solution might do the trick. This is not
>> well tested,
>> but it does make tables work as long as they are not broader than fill
>> column:
>>
>> (defadvice insert (around make-org-mode-newlines-hard activate)
>> "Make sure all org-mode functions insert hard newlines."
>> (if (and (eq major-mode 'org-mode)
>> (boundp 'longlines-mode) longlines-mode
>> (equal "org-" (substring (symbol-name this-command) 0 4)))
>> (let ((_beg (point)))
>> ad-do-it
>> (longlines-decode-region _beg (point)))
>> ad-do-it))
>>
>> (defadvice insert-before-markers (around make-org-mode-newlines-hard
>> activate)
>> "Make sure all org-mode functions insert hard newlines."
>> (if (and (eq major-mode 'org-mode)
>> (boundp 'longlines-mode) longlines-mode
>> (equal "org-" (substring (symbol-name this-command) 0 4)))
>> (let ((_beg (point)))
>> ad-do-it
>> (longlines-decode-region _beg (point)))
>> ad-do-it))
>>
>>
>>
>> _______________________________________________
>> Emacs-orgmode mailing list
>> Emacs-orgmode@gnu.org
>> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
>>
>
>
> --
> Mark Aufflick
> e: mark@pumptheory.com
> w: mark.aufflick.com
> p: +61 438 700 647
> f: +61 2 9436 4737
>
>
--
Carsten Dominik
Sterrenkundig Instituut "Anton Pannekoek"
Universiteit van Amsterdam
Kruislaan 403
NL-1098SJ Amsterdam
phone: +31 20 525 7477
next prev parent reply other threads:[~2007-03-26 15:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-18 1:43 org-mode and longlines-mode (especially tables) Mark Aufflick
2007-03-18 7:07 ` Carsten Dominik
2007-03-19 12:46 ` Alan Dove
2007-03-22 15:53 ` Carsten Dominik
2007-03-25 1:51 ` Mark Aufflick
2007-03-26 15:34 ` Carsten Dominik [this message]
2007-03-26 16:22 ` Carsten Dominik
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=b3615d07343dd6bd2f65b0b22ae4e7cb@science.uva.nl \
--to=dominik@science.uva.nl \
--cc=emacs-orgmode@gnu.org \
--cc=mark-emacs@aufflick.com \
/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).