Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 08-29-2010, 08:19 PM   #1
JaneFancher
Zealot
JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.
 
JaneFancher's Avatar
 
Posts: 123
Karma: 496
Join Date: Feb 2009
Location: Spokane, Washington
Device: Kindle2
Are the SGC_# a sigil code?

I'm having just more fun than should be legal with embedded fonts. Have just discovered that some of my books show just fine in Adobe Digital Editions, and some don't. Have tracked one problem to the sgc_1 code in the paragraph's html style code.

Basically, I had a font type, font size, ital, and this sgc code all in one style call in the html. When I took out the ital and the sgc code, I got my font, if not in italics. I can't figure what these sgc codes refer to. Can any one here help? And can I safely delete them?

Of course, one of the books that displays properly in ADE also has them. Go figure....

Thanks as always!
JaneFancher is offline   Reply With Quote
Old 08-29-2010, 11:01 PM   #2
theducks
Grand Sorcerer
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: 15,268
Karma: 6020309
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
Quote:
Originally Posted by JaneFancher View Post
I'm having just more fun than should be legal with embedded fonts. Have just discovered that some of my books show just fine in Adobe Digital Editions, and some don't. Have tracked one problem to the sgc_1 code in the paragraph's html style code.

Basically, I had a font type, font size, ital, and this sgc code all in one style call in the html. When I took out the ital and the sgc code, I got my font, if not in italics. I can't figure what these sgc codes refer to. Can any one here help? And can I safely delete them?

Of course, one of the books that displays properly in ADE also has them. Go figure....

Thanks as always!

In Code view, if you go near the top of the page:
there is a style section (olive color), when you use one of the Sigil style buttons (Bold, underline, center) a Sigil code appears here (not always the same SGC code, page to page), you can replace SGC codes with your own styles, . Just read the SGC defined style and replace the usage you found with yours that does similar things..
theducks is offline   Reply With Quote
 
Advertisement
Old 08-30-2010, 10:07 AM   #3
charleski
Wizard
charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.
 
Posts: 1,188
Karma: 727236
Join Date: Sep 2009
Device: PRS-505
Quote:
Originally Posted by JaneFancher View Post
I can't figure what these sgc codes refer to. Can any one here help? And can I safely delete them?
Sigil uses HTMLTidy to check and prettyprint the xhtml, and this will attempt to put all the styling into the css, so
<p><i>Some italic text</i></p>
becomes
<p class="sgc-1">Some italic text</p>
with
p.sgc-1 {font-style:italic}
in a style item in the header.

I think Valloric has said he'll add an option to turn this off in a future version, but for now the way to avoid it is to use
<p><em>Some italic text</em</p>
instead, which is better usage anyway.
charleski is offline   Reply With Quote
Old 08-30-2010, 02:13 PM   #4
JayCeeEll
Connoisseur
JayCeeEll doesn't litterJayCeeEll doesn't litterJayCeeEll doesn't litter
 
JayCeeEll's Avatar
 
Posts: 87
Karma: 204
Join Date: Dec 2007
Location: Exeter, Devon, UK
Device: PRS-300
Quote:
Originally Posted by charleski View Post
<p><em>Some italic text</em</p>
instead, which is better usage anyway.
I don't think it is - is one of the few times the <em> tag is correctly used. The majority of times you actually want <i>, e.g. titles of works, names of ships, foreign words, character thoughts and many others.
JayCeeEll is offline   Reply With Quote
Old 08-30-2010, 03:13 PM   #5
charleski
Wizard
charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.charleski ought to be getting tired of karma fortunes by now.
 
Posts: 1,188
Karma: 727236
Join Date: Sep 2009
Device: PRS-505
Quote:
Originally Posted by JayCeeEll View Post
I don't think it is - is one of the few times the <em> tag is correctly used. The majority of times you actually want <i>, e.g. titles of works, names of ships, foreign words, character thoughts and many others.
No, The whole point of html/css is that the presentational aspects are separated from the semantic. <em> indicates empahsis, which may be conveyed in different ways in different situations, eg if someone with impaired vision uses a text-to-speech system to read your book. If you want to italicise text for purely visual reasons you should be using css to do it, the <i> tag is retained purely because it's still so commonly used.
charleski is offline   Reply With Quote
Old 08-30-2010, 06:02 PM   #6
capidamonte
Not who you think I am...
capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!
 
capidamonte's Avatar
 
Posts: 346
Karma: 5337
Join Date: Jan 2010
Location: Honolulu
Device: Sony PRS-350
<em class="text_emphasis">
<em class="ship_name">
<em class="title_of_work">

And so on.

Lot of work, but it will let you distinguish how you want them to look: small caps, italics, font, etc.

Just don't overuse <span>s, that's nearly as bad as overusing <div>s.
capidamonte is offline   Reply With Quote
Old 09-03-2010, 06:07 PM   #7
JaneFancher
Zealot
JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.
 
JaneFancher's Avatar
 
Posts: 123
Karma: 496
Join Date: Feb 2009
Location: Spokane, Washington
Device: Kindle2
Thanks everyone!

Interesting input.

I kinda forgot about this because I figured it out. Pretty obvious what it was for when I actually LOOKED at the file. What remains strange to me is that it only put it in in a handful of places, when there were lots of italics throughout the (very long) book. Calibre, which created the epub file, had translated all the <i> code to a css code and that was present in all the instances where I used ital, including the handful that sigil inserted it's ital into. I'm sure there's a pattern, but I'm not going to bother to find it. I just took out the redundant code.

Thanks again.
JaneFancher is offline   Reply With Quote
Old 09-03-2010, 06:17 PM   #8
JaneFancher
Zealot
JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.JaneFancher has a complete set of Star Wars action figures.
 
JaneFancher's Avatar
 
Posts: 123
Karma: 496
Join Date: Feb 2009
Location: Spokane, Washington
Device: Kindle2
Oh...I actually have another question now on the same subject. If the idea is to use <em> for emphasis and to keep it out of the CSS...what is the alternative for bold <b>?

Thanks!
JaneFancher is offline   Reply With Quote
Old 09-03-2010, 06:28 PM   #9
capidamonte
Not who you think I am...
capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!
 
capidamonte's Avatar
 
Posts: 346
Karma: 5337
Join Date: Jan 2010
Location: Honolulu
Device: Sony PRS-350
<strong>
capidamonte is offline   Reply With Quote
Old 09-03-2010, 09:21 PM   #10
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 2,669
Karma: 15346071
Join Date: Apr 2010
Location: Phoenix, AZ
Device: Kindle2, iPad, KindleFire and NookColor
Quote:
Originally Posted by capidamonte View Post
<strong>
<manly>

Hitch is offline   Reply With Quote
Old 09-04-2010, 12:10 AM   #11
theducks
Grand Sorcerer
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: 15,268
Karma: 6020309
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
Quote:
Originally Posted by JaneFancher View Post
Oh...I actually have another question now on the same subject. If the idea is to use <em> for emphasis and to keep it out of the CSS...what is the alternative for bold <b>?

Thanks!
1) Why not in the CSS?
2) You can have/use more than one CSS at a time
3) You can add (file) local styles in the same place that Sigil puts theirs between the <style type="text/css"> </style>,
just take care to be unique.
theducks is offline   Reply With Quote
Old 09-04-2010, 03:05 AM   #12
capidamonte
Not who you think I am...
capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!
 
capidamonte's Avatar
 
Posts: 346
Karma: 5337
Join Date: Jan 2010
Location: Honolulu
Device: Sony PRS-350
Quote:
Originally Posted by Hitch View Post
<manly>


<virile>
capidamonte is offline   Reply With Quote
Old 09-04-2010, 06:37 AM   #13
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 2,669
Karma: 15346071
Join Date: Apr 2010
Location: Phoenix, AZ
Device: Kindle2, iPad, KindleFire and NookColor
Quote:
Originally Posted by capidamonte View Post
<virile>
<studly>
Hitch is offline   Reply With Quote
Old 09-04-2010, 01:48 PM   #14
capidamonte
Not who you think I am...
capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!capidamonte , Klaatu Barada Niktu!
 
capidamonte's Avatar
 
Posts: 346
Karma: 5337
Join Date: Jan 2010
Location: Honolulu
Device: Sony PRS-350
<talldarkandhandsome>
capidamonte is offline   Reply With Quote
Old 09-06-2010, 05:08 AM   #15
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 2,669
Karma: 15346071
Join Date: Apr 2010
Location: Phoenix, AZ
Device: Kindle2, iPad, KindleFire and NookColor
<hunkahunkaburninlove>
Hitch is offline   Reply With Quote
Reply

Tags
adobe digital editions, disappearing fonts, embedded fonts, sgc code

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Sigil 0.2.4 Valloric Sigil 16 09-09-2010 12:04 PM
Let's create a source code repository for DR 800 related code? jraf iRex 3 03-11-2010 01:26 PM
sigil 0.2.0 bobcdy Sigil 16 03-09-2010 09:31 AM
When do we get Sigil v0.2.0??? delphidb96 Sigil 0 10-08-2009 05:24 PM
Sigil 0.1.1 Valloric Sigil 29 08-08-2009 03:16 PM


All times are GMT -4. The time now is 04:01 AM.


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