<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Labeltext vertikal]]></title><description><![CDATA[<p>Hallo,</p>
<p>habe den Beitrag &quot; TLabel vertikal &quot; verfolgt.</p>
<p>einen Text in einem Label vertikal anzuordnen, bekomme ich nicht hin.<br />
einen Text in einer Image funktioniert.</p>
<p>wo ist hier der Fehler ?</p>
<p>Aufruf Image:</p>
<pre><code class="language-cpp">TRect R1 = Rect (0, 0, Image4-&gt;Width, Image4-&gt;Height);
AdvTextRect(&quot;Siegfried&quot;, Image4-&gt;Canvas, R1, 0, Image4-&gt;Height, &quot;HumstSlab712 Blk BT&quot;, 90);
</code></pre>
<p>Aufruf Label:</p>
<pre><code class="language-cpp">TRect R2 = Rect (0, 0, Label2-&gt;Width, Label2-&gt;Height);
AdvTextRect(&quot;9875&quot;, Label2-&gt;Canvas, R2, 0, Label2-&gt;Height, &quot;HumstSlab712 Blk BT&quot;, 90);
</code></pre>
<p>Routine:</p>
<pre><code class="language-cpp">void TFrameLinks1::AdvTextRect(AnsiString str,
                               TCanvas *pCanvas,
                               TRect R,
                               int X,
                               int Y,
                               String myFont,
                               double Angle)
//
//
//              erstellt am:    03. Juni 2005
//              geändert am:    03. Juni 2005
//
//
{
//
  int fontweight; 
  DWORD fontitalic, fontunderline, fontstrikeout; 
  // create font with specified angle 
  // bold? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsBold))
    fontweight = FW_BOLD; 
  else 
    fontweight = FW_NORMAL;
  // italic? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsItalic)) 
    fontitalic = true; 
  else 
    fontitalic = false; 
  // underline? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsUnderline)) 
    fontunderline = true; 
  else 
    fontunderline = false; 
  // strike out? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsStrikeOut))
    fontstrikeout = true; 
  else 
    fontstrikeout = false;
//
pCanvas-&gt;Font-&gt;Name = myFont;   
//
  HFONT hFont = CreateFont(pCanvas-&gt;Font-&gt;Height, 0, Angle*10, Angle*10, fontweight,
                    fontitalic, fontunderline, fontstrikeout, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, 
                    CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_DONTCARE, 
                    pCanvas-&gt;Font-&gt;Name.c_str()); 
  // assign created font to canvas 
  SelectObject(pCanvas-&gt;Handle, hFont); 
  // draw text on canvas 
  pCanvas-&gt;TextRect(R, X, Y, str); 
  // free font 
  DeleteObject(hFont); //
//
//
return ;
}
</code></pre>
<p>Gruß Siegfried</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/111708/labeltext-vertikal</link><generator>RSS for Node</generator><lastBuildDate>Wed, 24 Jun 2026 05:11:39 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/111708.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 04 Jun 2005 08:55:41 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Labeltext vertikal on Sat, 04 Jun 2005 08:55:41 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>habe den Beitrag &quot; TLabel vertikal &quot; verfolgt.</p>
<p>einen Text in einem Label vertikal anzuordnen, bekomme ich nicht hin.<br />
einen Text in einer Image funktioniert.</p>
<p>wo ist hier der Fehler ?</p>
<p>Aufruf Image:</p>
<pre><code class="language-cpp">TRect R1 = Rect (0, 0, Image4-&gt;Width, Image4-&gt;Height);
AdvTextRect(&quot;Siegfried&quot;, Image4-&gt;Canvas, R1, 0, Image4-&gt;Height, &quot;HumstSlab712 Blk BT&quot;, 90);
</code></pre>
<p>Aufruf Label:</p>
<pre><code class="language-cpp">TRect R2 = Rect (0, 0, Label2-&gt;Width, Label2-&gt;Height);
AdvTextRect(&quot;9875&quot;, Label2-&gt;Canvas, R2, 0, Label2-&gt;Height, &quot;HumstSlab712 Blk BT&quot;, 90);
</code></pre>
<p>Routine:</p>
<pre><code class="language-cpp">void TFrameLinks1::AdvTextRect(AnsiString str,
                               TCanvas *pCanvas,
                               TRect R,
                               int X,
                               int Y,
                               String myFont,
                               double Angle)
//
//
//              erstellt am:    03. Juni 2005
//              geändert am:    03. Juni 2005
//
//
{
//
  int fontweight; 
  DWORD fontitalic, fontunderline, fontstrikeout; 
  // create font with specified angle 
  // bold? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsBold))
    fontweight = FW_BOLD; 
  else 
    fontweight = FW_NORMAL;
  // italic? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsItalic)) 
    fontitalic = true; 
  else 
    fontitalic = false; 
  // underline? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsUnderline)) 
    fontunderline = true; 
  else 
    fontunderline = false; 
  // strike out? 
  if (pCanvas-&gt;Font-&gt;Style.Contains(fsStrikeOut))
    fontstrikeout = true; 
  else 
    fontstrikeout = false;
//
pCanvas-&gt;Font-&gt;Name = myFont;   
//
  HFONT hFont = CreateFont(pCanvas-&gt;Font-&gt;Height, 0, Angle*10, Angle*10, fontweight,
                    fontitalic, fontunderline, fontstrikeout, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, 
                    CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_DONTCARE, 
                    pCanvas-&gt;Font-&gt;Name.c_str()); 
  // assign created font to canvas 
  SelectObject(pCanvas-&gt;Handle, hFont); 
  // draw text on canvas 
  pCanvas-&gt;TextRect(R, X, Y, str); 
  // free font 
  DeleteObject(hFont); //
//
//
return ;
}
</code></pre>
<p>Gruß Siegfried</p>
]]></description><link>https://www.c-plusplus.net/forum/post/802017</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/802017</guid><dc:creator><![CDATA[Beppo]]></dc:creator><pubDate>Sat, 04 Jun 2005 08:55:41 GMT</pubDate></item><item><title><![CDATA[Reply to Labeltext vertikal on Sat, 04 Jun 2005 09:51:58 GMT]]></title><description><![CDATA[<p>Funktioniert völlig problemlos auch mit TLabel.<br />
Du solltest natürlich sicherstellen, dass das Label auch entsprechend gross dimensioniert ist, um etwas anzeigen zu können.</p>
<p>In Zukunft Nachfragen zu einem Thema aber bitte im ursprünglichen Thread stellen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/802046</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/802046</guid><dc:creator><![CDATA[Jansen]]></dc:creator><pubDate>Sat, 04 Jun 2005 09:51:58 GMT</pubDate></item></channel></rss>