Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 12-10-2012, 06:59 AM   #1
Andy Sinden
Member
Andy Sinden began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2012
Device: pc
Remove contents page underlines in epub book using Sigil

Can I use Sigil to remove the underlines on the epub contents page please. Highlighting the underscored words I want to have plain and clicking on the underscore format icon doesn't do it.
Andy Sinden is offline   Reply With Quote
Old 12-10-2012, 07:56 AM   #2
mncowboy
Wanderer
mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.
 
mncowboy's Avatar
 
Posts: 106
Karma: 472218
Join Date: Jan 2011
Device: Kindle 3, PaperWhite 2
Check the styling that is assigned to the entries. In the style for those elements, include the following:
text-decoration:none;
That will show te entries without the underline.
Bob
mncowboy is offline   Reply With Quote
Advert
Old 12-10-2012, 08:28 AM   #3
Gunnerp245
Gadget Freak
Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.Gunnerp245 ought to be getting tired of karma fortunes by now.
 
Gunnerp245's Avatar
 
Posts: 1,169
Karma: 1043832
Join Date: Nov 2007
Location: US
Device: EE, Note 8
Quote:
Originally Posted by Andy Sinden View Post
Can I use Sigil to remove the underlines on the epub contents page please. Highlighting the underscored words I want to have plain and clicking on the underscore format icon doesn't do it.
Check for <a> tags; Interesting...
Gunnerp245 is offline   Reply With Quote
Old 12-10-2012, 09:53 AM   #4
Andy Sinden
Member
Andy Sinden began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2012
Device: pc
Quote:
Originally Posted by mncowboy View Post
Check the styling that is assigned to the entries. In the style for those elements, include the following:
text-decoration:none;
That will show te entries without the underline.
Bob
Thanks Bob. Tried adding it, using = instead of - and adding " " around decoration:none but the underlines were still there in book view. Do I need to do anything else before going to book view. I added this, first in one, which didn't work, then the other, in the lines

<link href="../Styles/stylesheet.css" rel="stylesheet" type="text/css" /> and

<link href="../Styles/page_styles.css" rel="stylesheet" type="text/css" />

after the "text/css" in each case.

Thanks...............Andy
Andy Sinden is offline   Reply With Quote
Old 12-10-2012, 10:33 AM   #5
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,807
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
in code view:
find the line with the underline showing (in the book view)
Right-click on the class='<name>' ; select ;Goto Link or style

That is where you set text decoration to none
No equal, no quotes
If text-decoration: none;
does not exist: insert the line
theducks is offline   Reply With Quote
Advert
Old 12-10-2012, 11:01 AM   #6
mncowboy
Wanderer
mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.
 
mncowboy's Avatar
 
Posts: 106
Karma: 472218
Join Date: Jan 2011
Device: Kindle 3, PaperWhite 2
Andy: Are you using an external stylesheet? Do you have the files stylesheet.css and page_styles.css in the styles folder?
Could you include the first part of your document here? The code view, from the begining to the first few entries in your Table of Contents.
mncowboy is offline   Reply With Quote
Old 12-10-2012, 11:09 AM   #7
Andy Sinden
Member
Andy Sinden began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2012
Device: pc
Quote:
Originally Posted by theducks View Post
in code view:
find the line with the underline showing (in the book view)
Right-click on the class='<name>' ; select ;Goto Link or style

That is where you set text decoration to none
No equal, no quotes
If text-decoration: none;
does not exist: insert the line
Thanks Ducks, I'm staff to 1 cat and that's enough (it is ginger though). Had a look at this and all lines that i don't want underlined have the text decoration set to none. There is no ; at the end of the lines, so I added it to one line and this made no difference, Out of curiosity I looked at a line which is already not underlined and which is fine and its text decoration is set to underlined. (it is the CONTENTS heading to the contents page).
Andy Sinden is offline   Reply With Quote
Old 12-10-2012, 12:02 PM   #8
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,807
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
every attribute ( typical 1 per line) should end with a ; (the last before the } is optional)

IIRC text-decoration: underline; is a default if not specified

Validate (right-click on the filename in the book browser) your CSS, it probably has a error that blocks its proper use.
theducks is offline   Reply With Quote
Old 12-10-2012, 12:20 PM   #9
Andy Sinden
Member
Andy Sinden began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2012
Device: pc
Quote:
Originally Posted by mncowboy View Post
Andy: Are you using an external stylesheet? Do you have the files stylesheet.css and page_styles.css in the styles folder?
Could you include the first part of your document here? The code view, from the begining to the first few entries in your Table of Contents.
Hi - No, I'm not using external sheets, they were built up automatically. My book is in word, i converted it to HTML, added it to Calibre then converted it to epub, then loaded it to Sigil.

Yes, both stylesheet.css and page_styles.css are in the styles folder.

The style for the lines i don't want underlined already has the none entered, as shown below:
}
.calibre6 {
text-decoration: none

The style for the Contents page heading itself is not underlined in book view (which is what i want so is OK). But the code is as follows:

.pcalibre:visited {
color: purple;
text-decoration: underline

Seems the wrong way round to me!
Andy Sinden is offline   Reply With Quote
Old 12-10-2012, 01:03 PM   #10
mncowboy
Wanderer
mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.
 
mncowboy's Avatar
 
Posts: 106
Karma: 472218
Join Date: Jan 2011
Device: Kindle 3, PaperWhite 2
It would still be helpful to see how the first few entries in your Table of Contents is coded - we should be able to trace the styling from that.
mncowboy is offline   Reply With Quote
Old 12-10-2012, 01:27 PM   #11
Andy Sinden
Member
Andy Sinden began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Dec 2012
Device: pc
Quote:
Originally Posted by mncowboy View Post
It would still be helpful to see how the first few entries in your Table of Contents is coded - we should be able to trace the styling from that.
Thanks for helping cowboy(From a Beefheart line I wonder?).

Here it is:

<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">


html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="Microsoft Word 14 (filtered)" name="Generator" />

<title>The Book by me; from South Africa to Cornwall and back</title>
<link href="../Styles/stylesheet.css" rel="stylesheet" type="text/css" />
<link href="../Styles/page_styles.css" rel="stylesheet" type="text/css" />
</head>

<body class="calibre" link="blue" vlink="purple">
<p><span class="calibre4"><br class="calibre5" clear="all" id="calibre_pb_0" /></span></p>

<p class="MsoNormal1"><b class="calibre2"><span class="calibre1">&nbsp;</span></b></p>

<p class="MsoToc"><a class="pcalibre pcalibre1" id="toc">CONTENTS</a></p>

<p class="MsoToc">&nbsp;</p>

<p class="MsoToc1"><a class="pcalibre pcalibre1" href="../Text/F%26S%20book%203.2%20bullet%20indents%20para%20spa cing%2C%20uline%20contents%20links%20removed_split _002.htm#_Toc342575596"><span class="calibre6">Foreword</span></a></p>

<p class="MsoToc1"><a class="pcalibre pcalibre1" href="../Text/F%26S%20book%203.2%20bullet%20indents%20para%20spa cing%2C%20uline%20contents%20links%20removed_split _003.htm#_Toc342575597"><span class="calibre6">Introduction</span></a></p>

signing off now until tomorrow a.m. thanks for your help so far.
Andy Sinden is offline   Reply With Quote
Old 12-10-2012, 02:01 PM   #12
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,807
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
You have a stylesheet(s) (all those calibre#) and Not inline styling.
You have 5 (that I can see) things possibly affecting.

the ':visited:', once it has been visited (in anyway)
and possibly: MsToc, pcalibre1, pcalibre and pcalibre6


Then you have a selector mismatch
pcalibre6 is not the same as p.calibre6 <not a normal calibre usage
or .calibre6
theducks is offline   Reply With Quote
Old 12-10-2012, 07:31 PM   #13
mncowboy
Wanderer
mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.
 
mncowboy's Avatar
 
Posts: 106
Karma: 472218
Join Date: Jan 2011
Device: Kindle 3, PaperWhite 2
theducks is correct. If you want all the links to not be underlined, make sure the line
text-decoration:none;
exists in the style sheet for each of those classes in the stylesheets. Check the stylesheets for an
a:link, a:visited, and MsoHyperlink as well. Keep trying - you'll get there!
mncowboy is offline   Reply With Quote
Old 12-10-2012, 08:29 PM   #14
Ripplinger
350 Hoarder
Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.Ripplinger ought to be getting tired of karma fortunes by now.
 
Ripplinger's Avatar
 
Posts: 3,574
Karma: 8281267
Join Date: Dec 2010
Location: Midwest USA
Device: Sony PRS-350, Kobo Glo & Glo HD, PW2
I wanted to try this out and like Andy Sinden, was failing horribly. I put that line into every single style in my stylesheet.css and still had underscores.

Then I added this at the top of the TOC page only within <style> and </style> and it works:
a { text-decoration:none }

It's getting the underscore not from the style text but from the a in <a href...>. You could do it also adding a { text-decoration:none } to your stylesheet.css file as well and it will work (don't put the usual period before the a if you add it to your stylesheet, it won't work).
Ripplinger is offline   Reply With Quote
Old 12-10-2012, 09:10 PM   #15
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,552
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by Ripplinger View Post
It's getting the underscore not from the style text but from the a in <a href...>. You could do it also adding a { text-decoration:none } to your stylesheet.css file as well and it will work (don't put the usual period before the a if you add it to your stylesheet, it won't work).
You gotta do what works for you, but you should be able to assign the decoration attribute to a css class that's assigned to the different <a> tags. Your approach certainly makes sense if you don't ever want any of your links to be underlined, but it's possible to do it with classes rather than elements.

I think a big part of the problem here is that there's sooo many inherited attributes in this case. The <a> tags alone have two distinct classes assigned (though I can't for the life me imagine why that would be necessary). Then there's the <span>'s class, the <p>'s class, and even a few link attributes inherited from <body> tag (not to mention any css that may be assigned to the <body>'s class). There's just too much going on there. And that's what we can see. Is there any overlap between the two css files? Do the css files already have any attributes directly assigned to html elements in addition to the various class definitions?
DiapDealer is offline   Reply With Quote
Reply

Tags
remove underlines


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Epub to PDF can't remove page breaks between headers Vykan12 Calibre 11 07-25-2012 03:01 AM
can i remove the cover image from the end of epub book? granturissimus Conversion 2 11-14-2011 09:14 PM
Remove first page of Calibre Converted epub Run62 Calibre 2 08-03-2011 09:44 PM
903 missing page numbers in table of contents (EPUB) ANico PocketBook 4 05-19-2011 08:12 AM
remove table of contents cybmole Calibre 4 10-15-2010 10:21 AM


All times are GMT -4. The time now is 04:28 PM.


MobileRead.com is a privately owned, operated and funded community.