Jump to content

Help in overlining

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
5 replies to this topic

#1
Renee55

Renee55

    Newbie

  • Members
  • Pip
  • 5 posts
So far I have this:

<html>
<head><title>Example</title></head>
<body>Example</body>
<p>
<td align="center" width="15"><font face="Verdenia">__</td>
<tr>
<td align="center" width="15"><font face="Verdenia" size="2"><b>22</b></font></td>
</html>

I get __ 22.

I am trying to get this:
__
22


Thanks for your help in advance.

#2
dbug

dbug

    Programmer

  • Members
  • PipPipPipPip
  • 155 posts
You are using TD and TR tags, it would be better to use these tags inside a TABLE. However I don't think you need these tags. BODY tag should not be closed before the page content.

Instead of <tr> use <br /> to add a breakline. You should also close all tags (<p> is not closed)

<html>

  <head>

    <title>Example</title>

  </head>

<body>

  Example

  <p>

    <font face="Verdenia">__</font>

    <br />

    <font face="Verdenia" size="2"><b>22</b></font>

  </p>

</html>


#3
wim DC

wim DC

    Writes binary right handed and hex left handed

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 2,084 posts
Yea, it probably doesn't know you're willing to use a table. (td = table data (cell) - tr = table row)
These should be put in <table> </table> tags.

Adding
style="text-decoration: overline;"
To your font, or div, or <p> or anything will most likely give the best results. As it's contentSize independant.
like:
<font face="Verdenia" style="text-decoration: overline">test</font>


#4
gokuajmes

gokuajmes

    Programming God

  • Members
  • PipPipPipPipPipPipPip
  • 518 posts
just adding up to Oxano's code, define a inline css style element or write a external css sheet then create a css class as follows:
.overLine
{
text-decoration:overline;
}

then you can add this as class to html elements that needs overline like below
<table>
<th>Name</th><th>Age</th><th>Place</th>
<tr>
<td>Jill</td><td class="overline">20</td><td>USA</td>
</tr>
<tr>
<td>Jack</td><td class="overline">21</td><td>Russia</td>
</tr>
<tr>
<td>Rack</td><td class="overline">22</td><td>UK</td>
</tr></table>

hope things are cleared up now

#5
Renee55

Renee55

    Newbie

  • Members
  • Pip
  • 5 posts
Thanks for all of your help. I do have one more question about overlining. Is there a way to overline each letter or number in a sentence? For example:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
T H AN K S F OR Y OU R H E L P !

The overline isn't quite lining up right.

#6
gokuajmes

gokuajmes

    Programming God

  • Members
  • PipPipPipPipPipPipPip
  • 518 posts
Well i suppose you are overlining each number in the sequence, but isn't that what you wanted?
try the below to see the difference
<div style="text-decoration:overline">This is a overlined div content</div>
and
<style>
.ovr
{
text-decoration:overline;
}
</style>
<div><span class="ovr">this</span> <span class="ovr">is</span> <span class="ovr">a</span><span class="ovr">overlined</span> <span class="ovr">div</span> <span class="ovr">content</span></div>