473,320 Members | 1,876 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Draw vertical text

The text for the chart Y-axis title is to be drawn vertically. Here is
the snippet of my code.
.....
StringFormat drawFormat = new StringFormat();
drawFormat.FormatFlags = StringFormatFlags.DirectionVertical ;

//g is object of type System.Drawing.Graphics
g.DrawString("Period", font, Brushes.Black, 10, 10, drawFormat);
.....
Standard functionality allows to do that but the text is drawn from the
top to the bottom whereas I need the text to be drawn from the bottom
to the top (as it is more usual for users). How can I do it?

May 10 '06 #1
2 2159
There might be a way to do it, but I wonder if you are accomplishing with your code the same thing that can be accomplished using CSS:

<div style="writing-mode: tb-rl;">This is a test</div>

This type of vertical text is for foreign language support and is not a complete vertical text feature.

--
Greg Collins [InfoPath MVP]
Visit Brain Trove ( http://www.BrainTrove.com )
May 10 '06 #2

Greg Collins [InfoPath MVP] wrote:
There might be a way to do it, but I wonder if you are accomplishing with your code the same thing that can be accomplished using CSS:

<div style="writing-mode: tb-rl;">This is a test</div>

This type of vertical text is for foreign language support and is not a complete vertical text feature.

--
Greg Collins [InfoPath MVP]
Visit Brain Trove ( http://www.BrainTrove.com )


Thanks for help. It is interesting and usefull feature of CSS I don't
know before.
Solution of my problem was prompted in another group yet. It can be
resolved with rotating X and Y axis before drawing (methods
TranslateTransform and RotateTransform of System.Drawing.Graphics
object).

May 11 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Kai Grossjohann | last post by:
I have a file which contains component definitions, along with their x/y coordinates and width and height. Examples for components are a short text string, a text entry field, a date entry field,...
1
by: Jerry | last post by:
Hi, I want to draw a reverse string, does anyone know how to implement it? And I want to draw a vertical string, it can be implemented by setting StringFormat.StringFormatFlags...
3
by: Maileen | last post by:
Hi, I would like to know if under VB.NET exist some component which allow us to draw a 3D line (instead to draw 2 lines - 1 white and 1 dark grey) ? thanks a lot, Maileen
0
by: MrNobody | last post by:
I made a custom user control which is supposed to be my own little simple gui data table and I extend from UserControl and set it's autoscroll property to true yet as I draw outside the vertical...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.