Re: [O] Shrinking columns after formula recalculation
Nicolas Goaziou writes: > Hello, > > Nick Dokos writes: > >> But since no good deed shall go unpunished, here's another related >> problem I ran into: with shrunk columns, I add a few more rows to the >> table with S-RET on the first column, recalculate to populate the >> added rows and then do an undo. That undoes the results of the >> recalculation but it also unshrinks the column. > > Yes, undo unshrinks. This is a good thing as one might not notice undone > changes within a shrunk column. > > Also, AFAIK, there is no elegant way (i.e., not writing `org-undo') to > circumvent the issue, if it is considered as such. > OK - thanks! -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: [O] Shrinking columns after formula recalculation
Hello, Nick Dokos writes: > But since no good deed shall go unpunished, here's another related > problem I ran into: with shrunk columns, I add a few more rows to the > table with S-RET on the first column, recalculate to populate the > added rows and then do an undo. That undoes the results of the > recalculation but it also unshrinks the column. Yes, undo unshrinks. This is a good thing as one might not notice undone changes within a shrunk column. Also, AFAIK, there is no elegant way (i.e., not writing `org-undo') to circumvent the issue, if it is considered as such. Regards, -- Nicolas Goaziou
Re: [O] Shrinking columns after formula recalculation
Nicolas Goaziou writes: > Hello, > > Nick Dokos writes: > >> I have a table with column width cookies. I shrink the columns with >> C-u C-c TAB and then I recalculate with C-c C-c on the #TBLFM >> line. The columns then get expanded and I have to do the C-u C-c TAB >> again after every recalculation. Is there a way to have the columns >> stay shrunk? >> >> Example: An unsolved problem in number theory: for what values of n >> is n! - 1 a prime? >> >> | n | n! -1 | prime? | >> |+---+| >> | / | <10> || >> | 30 | 26525285981219105863630847999 | 1 | >> | 31 |822283865417792281772556287999 | 0 | >> | 32 | 26313083693369353016721801215999 | 1 | >> | 33 | 868331761881188649551819440127999 | 1 | >> | 34 | 29523279903960414084761860964351999 | 0 | >> | 35 | 10333147966386144929513375231 | 0 | >> >> #+TBLFM: @3$2..@>$2 = fact($1) -1 :: @3$3..@>$3 = prime($2, 10) > > Fixed. Thank you. > Indeed - thank you! But since no good deed shall go unpunished, here's another related problem I ran into: with shrunk columns, I add a few more rows to the table with S-RET on the first column, recalculate to populate the added rows and then do an undo. That undoes the results of the recalculation but it also unshrinks the column. Thanks again! -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: [O] Shrinking columns after formula recalculation
Hello, Nick Dokos writes: > I have a table with column width cookies. I shrink the columns with > C-u C-c TAB and then I recalculate with C-c C-c on the #TBLFM > line. The columns then get expanded and I have to do the C-u C-c TAB > again after every recalculation. Is there a way to have the columns > stay shrunk? > > Example: An unsolved problem in number theory: for what values of n > is n! - 1 a prime? > > | n | n! -1 | prime? | > |+---+| > | / | <10> || > | 30 | 26525285981219105863630847999 | 1 | > | 31 |822283865417792281772556287999 | 0 | > | 32 | 26313083693369353016721801215999 | 1 | > | 33 | 868331761881188649551819440127999 | 1 | > | 34 | 29523279903960414084761860964351999 | 0 | > | 35 | 10333147966386144929513375231 | 0 | > > #+TBLFM: @3$2..@>$2 = fact($1) -1 :: @3$3..@>$3 = prime($2, 10) Fixed. Thank you. Regards, -- Nicolas Goaziou