I'm trying to get a colored rectangle with text on top. (code at the bottom)
Height is set to 15 in the example, BUT i would like to get the height dynamicly set so that it adapts according to the amount of text that go's in the box.
How can i calculate the height?
+ the rectangle needs to be set first otherwise the text is under the colored rectangle and not visible! right?
PDF_setcolor($pdf, "both", "rgb", 0.666, 0.882, 0.980, 0);
PDF_rect($pdf, 340, 300, 75, 15);
PDF_fill_stroke($pdf);
PDF_setcolor($pdf, "fill", "rgb", 0, 0, 0, 0);
PDF_show_boxed($pdf, $text, 350, 300, 65, 15, "center");