From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Hendy Subject: Re: wrap text in table cell? Date: Wed, 7 Jul 2010 09:22:45 -0500 Message-ID: References: <4C33BB78.2060900@therogoffs.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0703226344==" Return-path: Received: from [140.186.70.92] (port=52654 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OWVWS-000540-9u for emacs-orgmode@gnu.org; Wed, 07 Jul 2010 10:22:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OWVWQ-00082U-NM for emacs-orgmode@gnu.org; Wed, 07 Jul 2010 10:22:48 -0400 Received: from mail-vw0-f41.google.com ([209.85.212.41]:45557) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OWVWQ-00082B-Ir for emacs-orgmode@gnu.org; Wed, 07 Jul 2010 10:22:46 -0400 Received: by vws1 with SMTP id 1so9820925vws.0 for ; Wed, 07 Jul 2010 07:22:45 -0700 (PDT) In-Reply-To: <4C33BB78.2060900@therogoffs.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: David Rogoff Cc: emacs-orgmode@gnu.org --===============0703226344== Content-Type: multipart/alternative; boundary=0016369c8e754f21e7048acce71a --0016369c8e754f21e7048acce71a Content-Type: text/plain; charset=ISO-8859-1 I was just asking about this. I'm not sure I figured out the best way, but it seems to work for me. I am exporting my tables to LaTeX primarily so I'm not sure if this is what you're looking for or not... Here's the recent series of messages: http://osdir.com/ml/emacs-orgmode-gnu/2010-07/msg00068.html The typical LaTeX table alignment is something like l|l|l for text which means left aligned text with vertical dividers. Instead of l you can use p{width} to specify a fixed column width which will wrap. In org, put this in your file and export it to LaTeX PDF #+ATTR_LaTeX: align= |l|l| |row 1|test of some really really long text because I want to see if it will wrap; what in the world will happen to it?| |row 2|test of some not so long test| #+ATTR_LaTeX: align= |l|p{10cm}| |row 1|test of some really really long text because I want to see if it will wrap; what in the world will happen to it?| |row 2|test of some not so long test| You can play with the 10cm value to figure out what you want to do. I essentially use trial and error. I export, check the result, and leave every 'fine' column as the l (left) alignment and then target ones with longer text to prevent them from going off the page. If you were looking for a more 'automatic' or 'intelligent' method, I'm not sure that it exists and not sure anyone could agree on the rules it should follow anyway (should it wrap a particular column? Just the longest one? Just the right-most one?). Does this help? John On Tue, Jul 6, 2010 at 6:25 PM, David Rogoff wrote: > I'm still learning org mode and have a question about table mode. Is there > a way to wrap text in a cell? I search the docs I could find and the > closest thing was putting in a cell which forced that column to be N > characters wide. That sort-or works, but isn't great. Am I missing > something, or can org-mode not do this? > > Thanks, > > David > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode > --0016369c8e754f21e7048acce71a Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I was just asking about this. I'm not sure I figured out the best way, = but it seems to work for me. I am exporting my tables to LaTeX primarily so= I'm not sure if this is what you're looking for or not...

Here's the recent series of messages: http://osdir.com/ml/emacs-orgmode-gn= u/2010-07/msg00068.html

The typical LaTeX table alignment is som= ething like l|l|l for text which means left aligned text with vertical divi= ders. Instead of l you can use p{width} to specify a fixed column width whi= ch will wrap. In org, put this in your file and export it to LaTeX PDF

#+ATTR_LaTeX: align=3D |l|l|
|row 1|test of some really really long = text because I want to see if it will wrap; what in the world will happen t= o it?|
|row 2|test of some not so long test|

#+ATTR_LaTeX: align= =3D |l|p{10cm}|
|row 1|test of some really really long text because I want to see if it=20 will wrap; what in the world will happen to it?|
|row 2|test of some not so long test|

You can play with the 10cm val= ue to figure out what you want to do. I essentially use trial and error. I = export, check the result, and leave every 'fine' column as the l (l= eft) alignment and then target ones with longer text to prevent them from g= oing off the page. If you were looking for a more 'automatic' or &#= 39;intelligent' method, I'm not sure that it exists and not sure an= yone could agree on the rules it should follow anyway (should it wrap a par= ticular column? Just the longest one? Just the right-most one?).

Does this help?


John

On Tu= e, Jul 6, 2010 at 6:25 PM, David Rogoff <david@therogoffs.com> wrote:
I'm still learning org mode and have a question about table mode. =A0Is= there a way to wrap text in a cell? =A0I search the docs I could find and = the closest thing was putting <N> in a cell which forced that column = to be N characters wide. =A0That sort-or works, but isn't great. =A0Am = I missing something, or can org-mode not do this?

Thanks,

=A0David

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gn= u.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

--0016369c8e754f21e7048acce71a-- --===============0703226344== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============0703226344==--