Skip to main content
Participating Frequently
August 18, 2010
Question

Align Image vertically center

  • August 18, 2010
  • 2 replies
  • 2108 views

Hi Guys,

Is there any way to show the image align vertically center to the text in the Layout component?

It shouldn't overlap on the next line. I am facing this problem since a long time. We would like to align the text as the refrence image attached below.

Any help will be highly appreciated.

Regards,

Faiz

This topic has been closed for replies.

2 replies

Participant
August 27, 2010

About verticaly align an image in text:

This has been a issue for me too since as2.

I have implemented some components to achive that in as2 and also in as3. But they are particular and cant be used by simply feeding htmlText to a TextField.

After the release of TLF I have also studied the opportunity to have inline images aligned verticaly.

This can be achived by making a custom component that set the baselineShift for the words before and after the image on the same line as image. Its not easy but I can think it can be done.

August 20, 2010

We definitely don't have this feature built-in. If the text is editable and the line where you wanted to display the image could move I'm not sure I'd want to attempt a solution. But if the image placement is relatively fixed you could display the image outside the text flow, then create a set of linked containers to flow the text through:

1. The text to the left of the image

2. The text to the right of the image

(these first two could be set at a height that only displayed one line of text, if that's what you're looking for)

3. The text below the image

Hope this helps,

Alan

_FaizAuthor
Participating Frequently
August 24, 2010

Hi,

Thanks for your response.

Earlier we were thinking Align image vertically center to the text would be built in feature.

In our case the position of image is not fixed, user can add multiple images anywhere dynamically.

As you know that in content publishing alignment and formatting is a major part.

Please update us about following fetures. Do we can expect about below features in coming release?

Align image vertically center built in feature in Text layout component?

Additional features like inserting mathematical and chemical formula in Text layout component.

Sample Image has been attached for a refrence.

Regards,

Faiz

August 24, 2010

Neither of those features are on our current road map. Formulas would be nice, but I expect someone else will need to implement them using the controls we expose. On centered images, I haven't even heard that discussed. Do you know of other text engines that implement this feature?