emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Vertically aligning table row contents
@ 2015-01-06 23:51 Peter Davis
  2015-01-07  0:14 ` John Hendy
  0 siblings, 1 reply; 9+ messages in thread
From: Peter Davis @ 2015-01-06 23:51 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1043 bytes --]

I'm trying to create a simple two-column table. The left column will 
show images of symbols used in the document, and the right column will 
explain what those images mean. So far, I have

--8<---------------cut here---------------start------------->8---

#+MACRO:  p   \includegraphics[scale=.35]{$1}
#+CAPTION: Document Symbols
#+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
| {{{p(./GreenDot.png)}}}  | This symbol indicates that the associated 
item is in a /normal/ or /successful/ state.                 |
| {{{p(./YellowDots.png)}}} | This symbol denotes a state of /concern/ 
or /potential trouble/ for the associated item.               |
| {{{p(./RedDots.png)}}}   | This symbol indicates that the associated 
item is in a /severely troubled/ or /non-functioning/ state. |

--8<---------------cut here---------------end--------------->8---


But what I'm getting is:

misaligned table

Is there a way to get both columns centered?

Thank you.

-pd


-- 
----
Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com


[-- Attachment #2.1: Type: text/html, Size: 2714 bytes --]

[-- Attachment #2.2: Screen Shot 2015-01-06 at 6.50.09 PM.png --]
[-- Type: image/png, Size: 69488 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-06 23:51 Vertically aligning table row contents Peter Davis
@ 2015-01-07  0:14 ` John Hendy
  2015-01-07  0:16   ` Peter Davis
  0 siblings, 1 reply; 9+ messages in thread
From: John Hendy @ 2015-01-07  0:14 UTC (permalink / raw)
  To: Peter Davis; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1173 bytes --]

On Jan 6, 2015 5:52 PM, "Peter Davis" <pfd@pfdstudio.com> wrote:
>
> I'm trying to create a simple two-column table. The left column will show
images of symbols used in the document, and the right column will explain
what those images mean. So far, I have
>
> --8<---------------cut here---------------start------------->8---
>
> #+MACRO:  p   \includegraphics[scale=.35]{$1}
> #+CAPTION: Document Symbols
> #+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
> | {{{p(./GreenDot.png)}}}  | This symbol indicates that the associated
item is in a /normal/ or /successful/ state.                 |
> | {{{p(./YellowDots.png)}}} | This symbol denotes a state of /concern/ or
/potential trouble/ for the associated item.               |
> | {{{p(./RedDots.png)}}}   | This symbol indicates that the associated
item is in a /severely troubled/ or /non-functioning/ state. |
>
> --8<---------------cut here---------------end--------------->8---
>
>
> But what I'm getting is:
>
>
>
> Is there a way to get both columns centered?
>

Assuming you mean vertically?

John

> Thank you.
>
> -pd
>
>
> --
> ----
> Peter Davis
> The Tech Curmudgeon
> www.techcurmudgeon.com

[-- Attachment #2: Type: text/html, Size: 1647 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  0:14 ` John Hendy
@ 2015-01-07  0:16   ` Peter Davis
  2015-01-07  0:19     ` John Hendy
  0 siblings, 1 reply; 9+ messages in thread
From: Peter Davis @ 2015-01-07  0:16 UTC (permalink / raw)
  To: John Hendy; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1312 bytes --]


On 1/6/15 7:14 PM, John Hendy wrote:
>
>
> On Jan 6, 2015 5:52 PM, "Peter Davis" <pfd@pfdstudio.com 
> <mailto:pfd@pfdstudio.com>> wrote:
> >
> > I'm trying to create a simple two-column table. The left column will 
> show images of symbols used in the document, and the right column will 
> explain what those images mean. So far, I have
> >
> > --8<---------------cut here---------------start------------->8---
> >
> > #+MACRO:  p   \includegraphics[scale=.35]{$1}
> > #+CAPTION: Document Symbols
> > #+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
> > | {{{p(./GreenDot.png)}}}  | This symbol indicates that the 
> associated item is in a /normal/ or /successful/ state.                 |
> > | {{{p(./YellowDots.png)}}} | This symbol denotes a state of 
> /concern/ or /potential trouble/ for the associated item.               |
> > | {{{p(./RedDots.png)}}}   | This symbol indicates that the 
> associated item is in a /severely troubled/ or /non-functioning/ state. |
> >
> > --8<---------------cut here---------------end--------------->8---
> >
> >
> > But what I'm getting is:
> >
> >
> >
> > Is there a way to get both columns centered?
> >
>
> Assuming you mean vertically?
>
>
Yes, I did mean vertically. Sorry.

-pd

-- 
----
Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com


[-- Attachment #2: Type: text/html, Size: 2318 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  0:16   ` Peter Davis
@ 2015-01-07  0:19     ` John Hendy
  2015-01-07  1:00       ` Peter Davis
  0 siblings, 1 reply; 9+ messages in thread
From: John Hendy @ 2015-01-07  0:19 UTC (permalink / raw)
  To: Peter Davis; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1506 bytes --]

The top three Google hits for "align images and text table latex" seem
helpful. The first two suggest \raisebox.

Hopefully they help!
John

On Tue, Jan 6, 2015, 6:16 PM Peter Davis <pfd@pfdstudio.com> wrote:

>
> On 1/6/15 7:14 PM, John Hendy wrote:
>
>
> On Jan 6, 2015 5:52 PM, "Peter Davis" <pfd@pfdstudio.com> wrote:
> >
> > I'm trying to create a simple two-column table. The left column will
> show images of symbols used in the document, and the right column will
> explain what those images mean. So far, I have
> >
> > --8<---------------cut here---------------start------------->8---
> >
> > #+MACRO:  p   \includegraphics[scale=.35]{$1}
> > #+CAPTION: Document Symbols
> > #+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
> > | {{{p(./GreenDot.png)}}}  | This symbol indicates that the associated
> item is in a /normal/ or /successful/ state.                 |
> > | {{{p(./YellowDots.png)}}} | This symbol denotes a state of /concern/
> or /potential trouble/ for the associated item.               |
> > | {{{p(./RedDots.png)}}}   | This symbol indicates that the associated
> item is in a /severely troubled/ or /non-functioning/ state. |
> >
> > --8<---------------cut here---------------end--------------->8---
> >
> >
> > But what I'm getting is:
> >
> >
> >
> > Is there a way to get both columns centered?
> >
>
> Assuming you mean vertically?
>
>  Yes, I did mean vertically. Sorry.
>
>
> -pd
>
> --
> ----
> Peter Davis
> The Tech Curmudgeonwww.techcurmudgeon.com
>
>

[-- Attachment #2: Type: text/html, Size: 2660 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  0:19     ` John Hendy
@ 2015-01-07  1:00       ` Peter Davis
  2015-01-07  1:15         ` John Hendy
  0 siblings, 1 reply; 9+ messages in thread
From: Peter Davis @ 2015-01-07  1:00 UTC (permalink / raw)
  To: John Hendy; +Cc: emacs-orgmode


On 1/6/15 7:19 PM, John Hendy wrote:
>
> The top three Google hits for "align images and text table latex" seem 
> helpful. The first two suggest \raisebox.
>
> Hopefully they help!
> John
>
>

Thanks, John. Is there an org-mode way to do this?

Thank you.

-pd

-- 
----
Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  1:00       ` Peter Davis
@ 2015-01-07  1:15         ` John Hendy
  2015-01-07  1:40           ` Peter Davis
  0 siblings, 1 reply; 9+ messages in thread
From: John Hendy @ 2015-01-07  1:15 UTC (permalink / raw)
  To: Peter Davis; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 681 bytes --]

On Jan 6, 2015 7:00 PM, "Peter Davis" <pfd@pfdstudio.com> wrote:
>
>
> On 1/6/15 7:19 PM, John Hendy wrote:
>>
>>
>> The top three Google hits for "align images and text table latex" seem
helpful. The first two suggest \raisebox.
>>
>> Hopefully they help!
>> John
>>
>>
>
> Thanks, John. Is there an org-mode way to do this?
>

I've not used macros, but could you just add the raisebox code to it?

Like ... \raisebox{0.5\height}{\includegraphics[...]{$1}

instead of the current?

Just a stab in the dark as I'm unfamiliar with you org tackle code and the
latex solution!

John

> Thank you.
>
>
> -pd
>
> --
> ----
> Peter Davis
> The Tech Curmudgeon
> www.techcurmudgeon.com
>

[-- Attachment #2: Type: text/html, Size: 1117 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  1:15         ` John Hendy
@ 2015-01-07  1:40           ` Peter Davis
  2015-01-07  2:33             ` Nick Dokos
  0 siblings, 1 reply; 9+ messages in thread
From: Peter Davis @ 2015-01-07  1:40 UTC (permalink / raw)
  To: John Hendy; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1712 bytes --]


On 1/6/15 8:15 PM, John Hendy wrote:
>
>
> On Jan 6, 2015 7:00 PM, "Peter Davis" <pfd@pfdstudio.com 
> <mailto:pfd@pfdstudio.com>> wrote:
> >
> >
> > On 1/6/15 7:19 PM, John Hendy wrote:
> >>
> >>
> >> The top three Google hits for "align images and text table latex" 
> seem helpful. The first two suggest \raisebox.
> >>
> >> Hopefully they help!
> >> John
> >>
> >>
> >
> > Thanks, John. Is there an org-mode way to do this?
> >
>
> I've not used macros, but could you just add the raisebox code to it?
>
> Like ... \raisebox{0.5\height}{\includegraphics[...]{$1}
>
> instead of the current?
>
> Just a stab in the dark as I'm unfamiliar with you org tackle code and 
> the latex solution!
>
> John
>

Maybe that's the right track, but the obvious solution doesn't seem to work:

--8<---------------cut here---------------start------------->8---

#+MACRO:  p   \raisebox{-.5\height}{\includegraphics[scale=.35]{$1}}
#+CAPTION: Document Symbols
#+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
| {{{p(./GreenDot.png)}}}   | This symbol indicates that the associated 
item is in a /normal/ or /successful/ state.                 |
| {{{p(./YellowDots.png)}}} | This symbol denotes a state of /concern/ 
or /potential trouble/ for the associated item.               |
| {{{p(./RedDots.png)}}}    | This symbol indicates that the associated 
item is in a /severely troubled/ or /non-functioning/ state. |

--8<---------------cut here---------------end--------------->8---



> > Thank you.
> >
> >
> > -pd
> >
> > --
> > ----
> > Peter Davis
> > The Tech Curmudgeon
> > www.techcurmudgeon.com <http://www.techcurmudgeon.com>
> >
>

-- 
----
Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com


[-- Attachment #2: Type: text/html, Size: 4131 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  1:40           ` Peter Davis
@ 2015-01-07  2:33             ` Nick Dokos
  2015-01-07  3:08               ` Peter Davis
  0 siblings, 1 reply; 9+ messages in thread
From: Nick Dokos @ 2015-01-07  2:33 UTC (permalink / raw)
  To: emacs-orgmode

Peter Davis <pfd@pfdstudio.com> writes:

> Maybe that's the right track, but the obvious solution doesn't seem to work:
>
> --8<---------------cut here---------------start------------->8---
>
> #+MACRO:  p   \raisebox{-.5\height}{\includegraphics[scale=.35]{$1}}

Try

#+MACRO: p @@latex:\raisebox{-.5\height}{\includegraphics[scale=.35]{$1}}@@

See (info "(org) Quoting LaTeX code")


> #+CAPTION: Document Symbols
> #+ATTR_LATEX: :align lp{5in} :float nil :border 2 :frame border
> | {{{p(./GreenDot.png)}}}   | This symbol indicates that the associated item is in a /normal/ or /successful/ state.                 |
> | {{{p(./YellowDots.png)}}} | This symbol denotes a state of /concern/ or /potential trouble/ for the associated item.               |
> | {{{p(./RedDots.png)}}}    | This symbol indicates that the associated item is in a /severely troubled/ or /non-functioning/ state. |
>
> --8<---------------cut here---------------end--------------->8---
>

Nick

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Vertically aligning table row contents
  2015-01-07  2:33             ` Nick Dokos
@ 2015-01-07  3:08               ` Peter Davis
  0 siblings, 0 replies; 9+ messages in thread
From: Peter Davis @ 2015-01-07  3:08 UTC (permalink / raw)
  To: emacs-orgmode


On 1/6/15 9:33 PM, Nick Dokos wrote:
> Peter Davis <pfd@pfdstudio.com> writes:
>
>> Maybe that's the right track, but the obvious solution doesn't seem to work:
>>
>> --8<---------------cut here---------------start------------->8---
>>
>> #+MACRO:  p   \raisebox{-.5\height}{\includegraphics[scale=.35]{$1}}
> Try
>
> #+MACRO: p @@latex:\raisebox{-.5\height}{\includegraphics[scale=.35]{$1}}@@
>
> See (info "(org) Quoting LaTeX code")
That's it! I'm afraid the original macro definition was taken from an 
earlier response on this list, and I used it without totally 
understanding its details.

Thank you!
-pd


-- 
----
Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2015-01-07  3:08 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-06 23:51 Vertically aligning table row contents Peter Davis
2015-01-07  0:14 ` John Hendy
2015-01-07  0:16   ` Peter Davis
2015-01-07  0:19     ` John Hendy
2015-01-07  1:00       ` Peter Davis
2015-01-07  1:15         ` John Hendy
2015-01-07  1:40           ` Peter Davis
2015-01-07  2:33             ` Nick Dokos
2015-01-07  3:08               ` Peter Davis

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).