Re: [O] [bug, org-table] new hline doesn't update formula
Rasmus ras...@gmx.us writes: Nicolas Goaziou m...@nicolasgoaziou.fr writes: Consider this example: |---+---+---| | a | b | c | | d | e | f | |---+---+---| | 1 | 2 | 3 | | 4 | 5 | 6 | |---+---+---| | 5 | 7 | 9 | #+TBLFM: @5=vsum(@II..@III) [...] What should happen to the formula if hline is inserted between |1|2|3| and |4|5|6|? Good question. I'm not sure. While not necessarily the most obvious I think in that case the formula should be unchanged. But it's not obvious. Another tricky example | 1 | || | 2 | | 3 | | 4 | || | 5 | || | 14 | #+TBLFM: @6=vsum(@I..@III) What if we insert a hline between |3| and |4|? I assume it should become @I..@. Yet, the difference between it and the case before is subtle, and hard to explain. That leads me to the next question: should we really mess with this? Regards,
Re: [O] [bug, org-table] new hline doesn't update formula
Rasmus writes: Nicolas Goaziou m...@nicolasgoaziou.fr writes: That leads me to the next question: should we really mess with this? Maybe not. Perhaps there's a reason for the current implementation. Agreed. However, it seems a good opportunity to alert the user to the fact that Org didn't touch the table formulas because it doesn't know what's right or wrong and expects the user to clean up. Regards, Achim. -- +[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+ Waldorf MIDI Implementation additional documentation: http://Synth.Stromeko.net/Downloads.html#WaldorfDocs
Re: [O] [bug, org-table] new hline doesn't update formula
Nicolas Goaziou m...@nicolasgoaziou.fr writes: That leads me to the next question: should we really mess with this? Maybe not. Perhaps there's a reason for the current implementation. —Rasmus -- . . . It begins of course with The Internet. A Net of Peers
Re: [O] [bug, org-table] new hline doesn't update formula
Hello, Rasmus ras...@gmx.us writes: Consider this example: |---+---+---| | a | b | c | | d | e | f | |---+---+---| | 1 | 2 | 3 | | 4 | 5 | 6 | |---+---+---| | 5 | 7 | 9 | #+TBLFM: @5=vsum(@II..@III) Insert a hline after |a|b|c|. The formula is now broken. What should happen to the formula if hline is inserted between |1|2|3| and |4|5|6|? Expected behavior: org-table-insert-hline should call org-table-fix-formulas, though this does not currently support hlines, it seems. I have no idea how trivial or hard this is to fix this... But hints or fixes are appreciated. It doesn't seem too hard to fix. I think we just need to extend `org-table-fix-formulas' to handle @I parts and call it from `org-table-insert-hline'. Anyway, actual fix depends on the answer to my initial question. Regards, -- Nicolas Goaziou
Re: [O] [bug, org-table] new hline doesn't update formula
Nicolas Goaziou m...@nicolasgoaziou.fr writes: Hello, Rasmus ras...@gmx.us writes: Consider this example: |---+---+---| | a | b | c | | d | e | f | |---+---+---| | 1 | 2 | 3 | | 4 | 5 | 6 | |---+---+---| | 5 | 7 | 9 | #+TBLFM: @5=vsum(@II..@III) Insert a hline after |a|b|c|. The formula is now broken. What should happen to the formula if hline is inserted between |1|2|3| and |4|5|6|? Good question. I'm not sure. While not necessarily the most obvious I think in that case the formula should be unchanged. But it's not obvious. Expected behavior: org-table-insert-hline should call org-table-fix-formulas, though this does not currently support hlines, it seems. I have no idea how trivial or hard this is to fix this... But hints or fixes are appreciated. It doesn't seem too hard to fix. I think we just need to extend `org-table-fix-formulas' to handle @I parts and call it from `org-table-insert-hline'. I guess something like that. Anyway, actual fix depends on the answer to my initial question. Yeah... —Rasmus -- . . . The proofs are technical in nature and provides no real understanding
[O] [bug, org-table] new hline doesn't update formula
Hi, Consider this example: |---+---+---| | a | b | c | | d | e | f | |---+---+---| | 1 | 2 | 3 | | 4 | 5 | 6 | |---+---+---| | 5 | 7 | 9 | #+TBLFM: @5=vsum(@II..@III) Insert a hline after |a|b|c|. The formula is now broken. Expected behavior: org-table-insert-hline should call org-table-fix-formulas, though this does not currently support hlines, it seems. I have no idea how trivial or hard this is to fix this... But hints or fixes are appreciated. —Rasmus -- The Kids call him Billy the Saint