# StyleSheet problem

**URL:** https://forum.kirupa.com/t/stylesheet-problem/264729
**Category:** flash
**Created:** [June 29, 2008, 7:03pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729 "2008-06-29T19:03:23Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![CayoHueso](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CayoHueso](https://forum.kirupa.com/u/CayoHueso)
#### Post date: [June 29, 2008, 7:03pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/1 "2008-06-29T19:03:23Z")

</div>

Hi,

I have the code below in a Flash movie, but the \<small\> tag breaks the line of text. Could you please give me any advice on this?

Thanks,  
CH

```auto

var styles:TextField.StyleSheet = new TextField.StyleSheet();
styles.setStyle("bodyText", {fontFamily: 'Arial,Helvetica,sans-serif', fontSize: '13px'});
styles.setStyle("small", {fontFamily: 'Arial,Helvetica,sans-serif', fontSize: '9px'});
this.createTextField("caption_txt", 3, 0, 0, 400, 55);
this.caption_txt.html=true;
this.caption_txt.multiline=true;
this.caption_txt.selectable=false;
this.caption_txt.wordWrap=true;
this.caption_txt.autoSize=true;
this.caption_txt.styleSheet = styles;
this.caption_txt.htmlText="<bodyText>Civilians <small>are</small> increasingly becoming the victims of Mexican soldiers waging a bloody campaign against narcotics cartels, TIME.com reports. In one instance, troops shot dead two women and three children traveling to a funeral. It's a drug war that the U.S. Congress is looking at </bodyText>"

```

---

<div class="post-metadata">

### Author: ![actionAction](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/actionaction/32/3987_2.png) [@actionAction](https://forum.kirupa.com/u/actionAction)
#### Post date: [June 29, 2008, 10:49pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/2 "2008-06-29T22:49:27Z")

</div>

Don’t use the small tag…

jk. Do you mean a like break?

---

<div class="post-metadata">

### Author: ![CayoHueso](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CayoHueso](https://forum.kirupa.com/u/CayoHueso)
#### Post date: [June 29, 2008, 11:22pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/3 "2008-06-29T23:22:00Z")

</div>

I need to create tags that will format parts of the text. I don’t know why it creates a line break. Do you have any advice on how to do this?

---

<div class="post-metadata">

### Author: ![actionAction](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/actionaction/32/3987_2.png) [@actionAction](https://forum.kirupa.com/u/actionAction)
#### Post date: [June 29, 2008, 11:32pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/4 "2008-06-29T23:32:08Z")

</div>

Try adding {fontFamily: ‘Arial,Helvetica,sans-serif’, fontSize: ‘9px’, **display: ‘inline’** }

---

<div class="post-metadata">

### Author: ![CayoHueso](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CayoHueso](https://forum.kirupa.com/u/CayoHueso)
#### Post date: [June 29, 2008, 11:44pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/5 "2008-06-29T23:44:40Z")

</div>

That works great! Thanks.  
One last thing: Is there any way to format letters so they appear superscript?

CH

---

<div class="post-metadata">

### Author: ![glosrfc](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/glosrfc/32/8334_2.png) [@glosrfc](https://forum.kirupa.com/u/glosrfc)
#### Post date: [June 29, 2008, 11:50pm UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/6 "2008-06-29T23:50:48Z")

</div>

No…you need to embed a superscript font

Check this link

> **[Superscript/Subscript with AS1.0/2.0](https://www.kirupa.com/forum/showthread.php?t=269348)**
>
> Got a web design/development question or just want to hang out with the most awesome people on the planet? Drop on in!

---

<div class="post-metadata">

### Author: ![CayoHueso](https://avatars.discourse-cdn.com/v4/letter/c/8e8cbc/32.png) [@CayoHueso](https://forum.kirupa.com/u/CayoHueso)
#### Post date: [June 30, 2008, 12:36am UTC](https://forum.kirupa.com/t/stylesheet-problem/264729/7 "2008-06-30T00:36:52Z")

</div>

Thanks,  
CH
