Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-03-16 Thread Shwouchk
Bastien,

Aaaah, thanks, it works great!
I looked for hours for a setting of the sort...

I do still think that this is a bug however: when I don't use the setting
you provided and don't use pretty-entities, after I place the
sub/superscript sign, the point gets places inside the braces. If I do use
pretty-entities however, the cursor gets placed *after* the brace pair, and
this is what causes problems - I would expect the point to get inside the
brace pair, as at least to my understanding, pretty-entities should change
the way things look, but not how they behave... What do you think?

Other than that, I have a feature suggestion that I'm throwing out there:
It would be really cool
I think it would be really cool if there was an option to expand
sub/superscript braces when the point is near them.

Other than that, I also noticed that after I export to PDF, my kill-ring
gets filled with a bunch of tex and/or output pieces. Is this
expected/known behaviour or should I investigate it further on my end?

Thanks,
Kosta


--
Kliakhandler Kosta
   Contact:
+972-547-567-052
 +1-347-281-7218
ko...@slumpy.org
 http://slumpy.org
   )°) )°( (°(


On Sat, Mar 15, 2014 at 8:29 AM, Bastien b...@gnu.org wrote:

 Hi,

 you want to set

 (setq org-pretty-entities-include-sub-superscripts nil)

 before using `org-cdlatex-mode'.

 HTH,

 --
  Bastien



Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-03-15 Thread Bastien
Hi,

you want to set

(setq org-pretty-entities-include-sub-superscripts nil)

before using `org-cdlatex-mode'.

HTH,

-- 
 Bastien



Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-03-15 Thread Anders Johansson

2014-02-23 16:20, Anders Johansson wrote:



Hi,
I used the configuration:

org-catch-invisible-edits 'show
org-pretty-entities t

together with org-cdlatex. This breaks the insertion of subscripts
and superscripts through org-cdlatex because _{} is fontified and the
{} are hidden so typing for example: a _ bc results in a_{b}c (or
sometimes a_bc, but should be a_{bc}) and gives the message
Unfolding invisible region around point before editing.

Setting org-catch-invisible-edits to nil let's cdlatex do it's work
so I guess an easy solution would be to let that in
org-cdlatex-underscore-caret.


Hi,
I realized that my solution won't work since
org-check-before-invisible-edit does it's work after
org-cdlatex-underscore-caret has called cdlatex-sub-superscript
and inserted _{}.

Maybe then org-catch-invisible-edits should be nil all the time in
org-cdlatex-mode? But this would be unexpected. Maybe this can be
treated as a special case in org-check-before-invisible-edit in some
way?


Digging into it some more it's actually the pretty entities folding
which is the problem, regardless of org-check-before-invisible-edit. The
cursor jumps out of the {}-brackets after the first character, when the
hiding/folding is done. I have no idea what should be done about this.




In case anyone has the same problem, my current workaraound for this is 
disabling pretty entities for sub/superscript when using cdlatex:


(add-hook 'cdlatex-mode-hook
 (lambda () (when (eq major-mode 'org-mode)
  (make-local-variable 'org-pretty-entities-include-sub-superscripts)
   (setq org-pretty-entities-include-sub-superscripts nil


Cheers,
Anders Johansson



Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-03-04 Thread shwouchk
Hello Anders,

Anders Johansson mejlaandersj at gmail.com writes:

 
 Hi,
 I used the configuration:
 
 org-catch-invisible-edits 'show
 org-pretty-entities t


Did you fish around enough to find a workaround? I have the same problem...

Cheers!




[O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-02-23 Thread Anders Johansson

Hi,
I used the configuration:

org-catch-invisible-edits 'show
org-pretty-entities t

together with org-cdlatex. This breaks the insertion of subscripts and 
superscripts through org-cdlatex because _{} is fontified and the {} are 
hidden so typing for example: a _ bc results in a_{b}c (or sometimes 
a_bc, but should be a_{bc}) and gives the message Unfolding 
invisible region around point before editing.


Setting org-catch-invisible-edits to nil let's cdlatex do it's work so I 
guess an easy solution would be to let that in 
org-cdlatex-underscore-caret.



Cheers,
Anders Johansson



Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-02-23 Thread Anders Johansson

Hi,
I used the configuration:

org-catch-invisible-edits 'show
org-pretty-entities t

together with org-cdlatex. This breaks the insertion of subscripts and 
superscripts through org-cdlatex because _{} is fontified and the {} 
are hidden so typing for example: a _ bc results in a_{b}c (or 
sometimes a_bc, but should be a_{bc}) and gives the message 
Unfolding invisible region around point before editing.


Setting org-catch-invisible-edits to nil let's cdlatex do it's work so 
I guess an easy solution would be to let that in 
org-cdlatex-underscore-caret.



Cheers,
Anders Johansson

Hi,
I realized that my solution won't work since 
org-check-before-invisible-edit does it's work after 
org-cdlatex-underscore-caret has called cdlatex-sub-superscript and 
inserted _{}.


Maybe then org-catch-invisible-edits should be nil all the time in 
org-cdlatex-mode? But this would be unexpected. Maybe this can be 
treated as a special case in org-check-before-invisible-edit in some way?



Cheers,
Andes Johansson



Re: [O] Bug: Problems with sub/super-script when using: org-cdlatex + org-pretty-entities + org-catch-invisible-edits

2014-02-23 Thread Anders Johansson



Hi,
I used the configuration:

org-catch-invisible-edits 'show
org-pretty-entities t

together with org-cdlatex. This breaks the insertion of subscripts 
and superscripts through org-cdlatex because _{} is fontified and the 
{} are hidden so typing for example: a _ bc results in a_{b}c (or 
sometimes a_bc, but should be a_{bc}) and gives the message 
Unfolding invisible region around point before editing.


Setting org-catch-invisible-edits to nil let's cdlatex do it's work 
so I guess an easy solution would be to let that in 
org-cdlatex-underscore-caret.



Hi,
I realized that my solution won't work since 
org-check-before-invisible-edit does it's work after 
org-cdlatex-underscore-caret has called cdlatex-sub-superscript 
and inserted _{}.


Maybe then org-catch-invisible-edits should be nil all the time in 
org-cdlatex-mode? But this would be unexpected. Maybe this can be 
treated as a special case in org-check-before-invisible-edit in some 
way?


Digging into it some more it's actually the pretty entities folding 
which is the problem, regardless of org-check-before-invisible-edit. The 
cursor jumps out of the {}-brackets after the first character, when the 
hiding/folding is done. I have no idea what should be done about this.


Cheers,
Anders Johansson