Question about pdf/writer

hey there all,

i am using ruby to make some pdf charts, but there is also a data table i
need to put in there.
i am using pdf/writer and so far so good, but i can't find anywhere that i
can change the color of the table text.
Anyone help me out on this?

thanks

You do it by changing the fill color prior to starting the table (IIRC).

-austin

···

On 11/8/07, shawn bright <nephish@gmail.com> wrote:

i am using ruby to make some pdf charts, but there is also a data table i
need to put in there.
i am using pdf/writer and so far so good, but i can't find anywhere that i
can change the color of the table text.
Anyone help me out on this?

--
Austin Ziegler * halostatue@gmail.com * http://www.halostatue.ca/
               * austin@halostatue.ca * You are in a maze of twisty little passages, all alike. // halo • statue
               * austin@zieglers.ca

Right, thanks Austin, sorry. I did not ask my question very clearly. I
need to be able to make one row of text one color, the next row of
text another color, etc... This i can't find out how to do. All of it
needs to be in the same table.

···

On Nov 8, 6:00 pm, Austin Ziegler <halosta...@gmail.com> wrote:

On 11/8/07, shawn bright <neph...@gmail.com> wrote:

> i am using ruby to make somepdfcharts, but there is also a data table i
> need to put in there.
> i am usingpdf/writerand so far so good, but i can't find anywhere that i
> can change thecolorof the table text.
> Anyone help me out on this?

You do it by changing the fillcolorprior to starting the table (IIRC).

-austin
--
Austin Ziegler * halosta...@gmail.com *http://www.halostatue.ca/
               * aus...@halostatue.ca *You are in a maze of twisty little passages, all alike. // halo • statue
               * aus...@zieglers.ca

You can get alternating row colors with SimpleTable, but that's about
all.. These are the shade_color and shade_color2 attributes.

If you have more questions about this or other things you encounter in
PDF::Writer, please join our mailing list. I have trouble keeping up
on RubyTalk these days :slight_smile:

http://rubyforge.org/mailman/listinfo/ruby-pdf-discuss

Also, as an aside, as of ruport-util 0.9, you might get a lot of love
out of Ruport for this kind of thing, if you're willing to poke around
a bit.

-greg

···

On Nov 9, 10:10 am, nephish <neph...@gmail.com> wrote:

Right, thanks Austin, sorry. I did not ask my question very clearly. I
need to be able to make one row of text one color, the next row of
text another color, etc... This i can't find out how to do. All of it
needs to be in the same table.

Whoops, I misunderstood. I don't think it will be possible (with the
current implementation) to set text color for individual rows.
Patches welcome though!

···

On Nov 9, 11:07 am, Gregory Brown <gregory.t.br...@gmail.com> wrote:

On Nov 9, 10:10 am, nephish <neph...@gmail.com> wrote:

> Right, thanks Austin, sorry. I did not ask my question very clearly. I
> need to be able to make one row of text one color, the next row of
> text another color, etc... This i can't find out how to do. All of it
> needs to be in the same table.

ok, gents, thanks for all your help, will keep poking around. Would
love to help with patches, maybe will some day, but am still a newbie.
Thanks again
sk

···

On Nov 9, 10:08 am, Gregory Brown <gregory.t.br...@gmail.com> wrote:

On Nov 9, 11:07 am, Gregory Brown <gregory.t.br...@gmail.com> wrote:

> On Nov 9, 10:10 am, nephish <neph...@gmail.com> wrote:

> > Right, thanks Austin, sorry. I did not ask my question very clearly. I
> > need to be able to make one row of text one color, the next row of
> > text another color, etc... This i can't find out how to do. All of it
> > needs to be in the same table.

Whoops, I misunderstood. I don't think it will be possible (with the
current implementation) to set text color for individual rows.
Patches welcome though!