Re: [WIN32LIB] Font Confusion

new topic     » goto parent     » topic index » view thread      » older message » newer message

This is a multi-part message in MIME format.

------=_NextPart_000_0022_01C225E7.CF593BC0
	charset="iso-8859-1"

Travis,
make each "control" a child Window that has no border. I think this will =
allow each to have its own font. I'll knock up an example for you. Also, =
I think you can create Owner-Drawn labels that allow you to set the =
fonts, so I'll research that too.

---------------
Derek.
  ----- Original Message -----=20
  From: Travis Beaty=20
  To: EUforum=20
  Sent: Sunday, July 07, 2002 5:02 PM
  Subject: [WIN32LIB] Font Confusion



  Hello All!

  =20

  I've got an interesting problem that I'm hoping someone can help me =
out with.  I have a group control on a tabItem.  On this group control, =
I originally had five labels, each of which needed to be able to have =
its own font, font color, and background color.  Unfortunately, after =
trying everything I could think of, as well as other folks' advice, I =
could not get the font color to change inside the label.  (I could do =
everything else.)  I tried setTextColor(), setPenColor(), even what API =
calls I knew, without success.

  =20

  So, I've decided to draw my own labels.  I've done this by simply =
drawing a filled rectangle corresponding to the boundaries of my =
"control," then writing within that rectangle using wPuts().  This =
seemed simple enough, until it came to changing the font before writing =
to the control.  When I do this, the font of the group box changes as =
well.  Is there any way that I can change the font of the pen without =
changing the font of the control?  This will be especially important, =
because, as I said, it is possible that each one of these five "labels" =
will have separate fonts.

  =20

  Any ideas about what to do would be greatly appreciated.

  =20

  Travis Beaty

  Evans, Colorado.

  =20

  =20





------=_NextPart_000_0022_01C225E7.CF593BC0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns=3D"http://www.w3.org/TR/REC-html40" xmlns:o =3D=20
"urn:schemas-microsoft-com:office:office" xmlns:w =3D=20
"urn:schemas-microsoft-com:office:word" xmlns:st1 =3D=20
"urn:schemas-microsoft-com:office:smarttags"><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3DWord.Document name=3DProgId>
<META content=3D"MSHTML 6.00.2716.2200" name=3DGENERATOR>
<META content=3D"Microsoft Word 10" name=3DOriginator><LINK=20
href=3D"cid:filelist.xml at 01C22551.E662AB80" =
rel=3DFile-List><o:SmartTagType=20
name=3D"State"=20
namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"></o:SmartTagT=
ype><o:SmartTagType=20
name=3D"City"=20
namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"></o:SmartTagT=
ype><o:SmartTagType=20
name=3D"place"=20
namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"></o:SmartTagT=
ype><!--[if gte mso 9]><xml>
 <o:OfficeDocumentSettings>
  <o:DoNotRelyOnCSS/>
 </o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
 <w:WordDocument>
  <w:GrammarState>Clean</w:GrammarState>
  <w:DocumentKind>DocumentEmail</w:DocumentKind>
  <w:EnvelopeVis/>
  <w:Compatibility>
   <w:BreakWrappedTables/>
   <w:SnapToGridInCell/>
   <w:WrapTextWithPunct/>
   <w:UseAsianBreakRules/>
  </w:Compatibility>
  <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
 </w:WordDocument>
</xml><![endif]--><!--[if !mso]>
<STYLE>st1\:* {
	BEHAVIOR: url(#default#ieooui)
}
</STYLE>
<![endif]-->
<STYLE>
<!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{mso-style-parent:"";
	margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman";
	mso-fareast-font-family:"Times New Roman";}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;
	text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;
	text-underline:single;}
span.EmailStyle17
	{mso-style-type:personal-compose;
	mso-style-noshow:yes;
	mso-ansi-font-size:10.0pt;
	mso-bidi-font-size:10.0pt;
	font-family:Arial;
	mso-ascii-font-family:Arial;
	mso-hansi-font-family:Arial;
	mso-bidi-font-family:Arial;
	color:windowtext;}
span.GramE
	{mso-style-name:"";
	mso-gram-e:yes;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;
	mso-header-margin:.5in;
	mso-footer-margin:.5in;
	mso-paper-source:0;}
div.Section1
	{page:Section1;}
-->
</STYLE>
<!--[if gte mso 10]>
<style>
 /* Style Definitions */=20
 table.MsoNormalTable
	{mso-style-name:"Table Normal";
	mso-tstyle-rowband-size:0;
	mso-tstyle-colband-size:0;
	mso-style-noshow:yes;
	mso-style-parent:"";
	mso-padding-alt:0in 5.4pt 0in 5.4pt;
	mso-para-margin:0in;
	mso-para-margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:10.0pt;
	font-family:"Times New Roman";}
</style>
<![endif]--></HEAD>
<BODY lang=3DEN-US style=3D"tab-interval: .5in" vLink=3Dpurple =
link=3Dblue=20
bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Travis,</FONT></DIV>
<DIV><FONT size=3D2>make each "control" a child Window that has no =
border. I think=20
this will allow each to have its own font. I'll knock up an example for =
you.=20
Also, I think you can create Owner-Drawn labels that allow you to set =
the fonts,=20
so I'll research that too.</FONT></DIV>
<DIV><FONT size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT size=3D2>---------------</FONT></DIV>
<DIV><FONT size=3D2>Derek.</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style=3D"FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV=20
  style=3D"BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: =
black"><B>From:</B>=20
  <A title=3Dtravis_beaty at mcleodusa.net=20
  href=3D"mailto:travis_beaty at mcleodusa.net">Travis Beaty</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>To:</B> <A =
title=3DEUforum at topica.com=20
  href=3D"mailto:EUforum at topica.com">EUforum</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Sent:</B> Sunday, July 07, 2002 =
5:02 PM</DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Subject:</B> [WIN32LIB] Font =
Confusion</DIV>
  <DIV><BR></DIV><PRE>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D The Euphoria =
Mailing List =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=20
</PRE>
  <DIV class=3DSection1>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: Arial">Hello=20
  All!<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: Arial">I=92ve got an =
interesting problem=20
  that I=92m hoping someone can help me out with.<SPAN=20
  style=3D"mso-spacerun: yes">&nbsp; </SPAN>I have a group control on a=20
  tabItem.<SPAN style=3D"mso-spacerun: yes">&nbsp; </SPAN>On this group =
control, I=20
  originally had five labels, each of which needed to be able to have =
its own=20
  font, font color, and background color.<SPAN style=3D"mso-spacerun: =
yes">&nbsp;=20
  </SPAN>Unfortunately, after trying everything I could think of, as =
well as=20
  other folks=92 advice, I could not get the font color to change inside =
the=20
  label. <SPAN style=3D"mso-spacerun: yes">&nbsp;</SPAN>(I could do =
everything=20
  else.)<SPAN style=3D"mso-spacerun: yes">&nbsp; </SPAN>I tried <SPAN=20
  class=3DGramE>setTextColor(</SPAN>), setPenColor(), even what API =
calls I knew,=20
  without success.<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: Arial">So, I=92ve decided to =
draw my own=20
  labels.<SPAN style=3D"mso-spacerun: yes">&nbsp; </SPAN>I=92ve done =
this by simply=20
  drawing a filled rectangle corresponding to the boundaries of my =
=93control,=94=20
  then writing within that rectangle using wPuts().<SPAN=20
  style=3D"mso-spacerun: yes">&nbsp; </SPAN>This seemed simple enough, =
until it=20
  came to changing the font before writing to the control. <SPAN=20
  style=3D"mso-spacerun: yes">&nbsp;</SPAN><SPAN class=3DGramE>When I do =
this, the=20
  font of the group box changes as well.</SPAN><SPAN=20
  style=3D"mso-spacerun: yes">&nbsp; </SPAN>Is there any way that I can =
change the=20
  font of the pen without changing the font of the control? <SPAN=20
  style=3D"mso-spacerun: yes">&nbsp;</SPAN>This will be especially =
important,=20
  because, as I said, it is possible that each one of these five =
=93labels=94 will=20
  have separate fonts.<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: Arial">Any ideas about what to =
do would=20
  be greatly appreciated.<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: Arial">Travis=20
  Beaty<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><st1:place><st1:City><FONT face=3DArial =
size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial">Evans</SPAN></FONT></st1:City><FONT=20
  face=3DArial size=3D2><SPAN style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial">,=20
  </SPAN></FONT><st1:State><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial">Colorado</SPAN></FONT></st1:State></st1:place><FONT=20
  face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial">.<o:p></o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P>
  <P class=3DMsoNormal><FONT face=3DArial size=3D2><SPAN=20
  style=3D"FONT-SIZE: 10pt; FONT-FAMILY: =
Arial"><o:p>&nbsp;</o:p></SPAN></FONT></P></DIV><PRE>=3D=3D^=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D
This email was sent to: ddparnell at bigpond.com

EASY UNSUBSCRIBE click here: <A =
href=3D"http://topica.com/u/?b1dd66.b2mL5y">http://topica.com/u/?b1dd66.b=
2mL5y</A>
Or send an email to: EUforum-unsubscribe at topica.com

T O P I C A -- Register now to manage your mail!
<A =
href=3D"http://www.topica.com/partner/tag02/register">http://www.topica.c=
om/partner/tag02/register</A>
=3D=3D^=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D</PRE></BLOCKQUOTE></B=

------=_NextPart_000_0022_01C225E7.CF593BC0--

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu