Hi Niklas,

To continue our exchange on the OOo dev list:
Thanks for your suggestion. I added a function in output2.cxx to extend the default alignment handling, call it when necessary, and it works great. There's still a problem, though. When I edit a field by pressing F2 or clicking on the string in the input window, the alignment of the cell temporarily reverts to the old default alignment. Alignment of the input window is OK, the only problem is the alignment of the cell. When the editing is done, the cell is refreshed properly, but during the editing the text suddenly gets realigned. How can I prevent this?

Another related question: I still have a problem when I import Excel documents with text direction set as "Context". Here also I have to make the setting based on the text content, but this time it's the text direction setting, and it's only with imported Excel documents. How could I handle that problem?

Thanks,
Alan

Niklas Nebel wrote:
>The alignment attribute is part of the cell attributes that are stored for cell ranges within a column in the >ScAttrArray class.

>But if you want to dynamically change the alignment based on content, including formula results, it's probably >better to extend the handling of "default" alignment that currently aligns text left, numbers right. Look for >occurences of SVX_HOR_JUSTIFY_STANDARD, especially in sc/source/ui/view/output2.cxx, which has >the code for text output.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to