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-12-2014, 11:51 AM   #1
kat7
Junior Member
kat7 began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Apr 2014
Device: none
Feature request: new CSS class from computed style

Hi Sigil,

I figured I'd share this idea for whatever it's worth (I'm that annoying person who isn't a programmer but has ideas that make me wish I was).

If Sigil had a tool where you could place the cursor at a particular point in the text, and then create a new CSS class based on the formatting of that text, that would be awesome for me.

So, if the particular text was in a <p class="W" id="X">, but also in a <span id="Y" style="Z">, the tool would take the ("computed") overall style expressed by the hierarchy of W, X, Y, and Z, and make a new, single CSS class with all that styling. I suppose it would have to prompt the user to name the class, and also to specify whether it should be for a block or for an inline element.

(Possibly helpful context: I routinely work on .epub files exported from InDesign, in which the layout person can create named "paragraph" and "character styles", which are directly translated to CSS classes. But the layout person can also apply "local" formatting in a haphazard manner which is not associated with their named styles. In the exported .epub, this local formatting is rendered as CSS classes called ParaOverride-15, CharOverride-107, and so forth.

The result is that some text in the epub is styled by way of three or four levels of confusingly named CSS, which makes it difficult to make a change without first untangling which CSS is overriding which other CSS. Also, text A may appear exactly the same as text B--so that in the ideal world they would be coded as the same element with the same class--however A may achieve its appearance using different classes than does text B, from unrelated "local" formatting applied in InDesign.)

Anyway just a thought in case it finds anyone else who feels similarly. And, if you have read this far, thank you for enduring my InDesign rant!

kat7 is offline   Reply With Quote
Old 12-14-2014, 05:21 PM   #2
st_albert
Guru
st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'
 
Posts: 696
Karma: 150000
Join Date: Feb 2010
Device: none
+1 on the InDesign rant.

I solve that problem in ID before exporting, by, for example, searching for all italic character strings and applying an appropriate named character style to them. Repeat for bold, etc. as needed. Then select the entire document and "clear all overrides."

Follow up with a severe lecture to whoever created the ID file in the first place, requesting that they never use local formatting overrides. They'll probably make YOU the new internal book designer.
st_albert is offline   Reply With Quote
Advert
Old 12-18-2014, 02:21 AM   #3
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Reduce the whole thing to raw text, and send it back for proper formatting.
eschwartz is offline   Reply With Quote
Old 12-21-2014, 02:27 PM   #4
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: 11,460
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by st_albert View Post
+1 on the InDesign rant.

I solve that problem in ID before exporting, by, for example, searching for all italic character strings and applying an appropriate named character style to them. Repeat for bold, etc. as needed. Then select the entire document and "clear all overrides."

Follow up with a severe lecture to whoever created the ID file in the first place, requesting that they never use local formatting overrides. They'll probably make YOU the new internal book designer.
We are the formatters for a number of print-layout houses--they can't abide the idea of making eBooks (for the amounts paid for eBooks), and we're always happy to do it. However, boy-o-boy-o, do we get some DOOZY INDD formatting.

When we establish a relationship with a print-layout house, we'll go through their first few, and make suggestions. However, there are some that come to us and we charge them as though we are making the file from PDF, rather than an INDD set, because the clean-up is just...ridiculous. As kat7 noted, once you start seeing "char-overrides" in the 60's, 70's, etc...it makes your eyes bleed.

Yes, a computed-style creator WOULD Be nice. That, and someone paying off my mortgage. I figure that they have about equivalent chances of actually happening, but just in case Santa was reading this thread, I'll plus-1 this. ;-)

(I must admit though: we do most of our INDD-export cleanups in Epsilon, not Sigil. Sorry, but there it is.)

Hitch
Hitch is offline   Reply With Quote
Old 12-29-2014, 04:14 AM   #5
jugaor
Enthusiast
jugaor began at the beginning.
 
jugaor's Avatar
 
Posts: 30
Karma: 10
Join Date: Jun 2011
Location: Lima, Peru
Device: Kindle 10Gen / Kobo Aura HD / Nook STR
Feature request: new CSS class from computed style

Quote:
Originally Posted by Hitch View Post



(I must admit though: we do most of our INDD-export cleanups in Epsilon, not Sigil. Sorry, but there it is.)
Hi.
Sorry for the ignorance, what is Epsilon?
(a link would be nice )

TIA
jugaor is offline   Reply With Quote
Advert
Old 12-29-2014, 06:19 AM   #6
drjenkins
Addict
drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.drjenkins ought to be getting tired of karma fortunes by now.
 
Posts: 250
Karma: 1702156
Join Date: Nov 2010
Device: Kindle Voyage
I'm pretty sure he's referring to Lugaru Epsilon, the editor for programmers.

http://www.lugaru.com/

It's not cheap at $250.00.
drjenkins is offline   Reply With Quote
Old 12-29-2014, 08:09 AM   #7
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: 11,460
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by drjenkins View Post
I'm pretty sure he's referring to Lugaru Epsilon, the editor for programmers.

http://www.lugaru.com/

It's not cheap at $250.00.
Yes, that's right.

Hitch
Hitch is offline   Reply With Quote
Old 12-29-2014, 08:29 AM   #8
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
Quote:
Originally Posted by drjenkins View Post
I'm pretty sure he's referring to Lugaru Epsilon, the editor for programmers.
He is a she.
Toxaris is offline   Reply With Quote
Old 12-29-2014, 08:47 AM   #9
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,897
Karma: 128597114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
But there is a bug in the computer CSS style. It's using px for the font-size and that's wrong. It should be using em.
JSWolf is offline   Reply With Quote
Old 12-29-2014, 10:27 AM   #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: 11,460
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by Toxaris View Post
He is a she.
S/he doesn't mind. ;-)

HItch
Hitch is offline   Reply With Quote
Old 01-01-2015, 01:50 AM   #11
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Epsilon sounds interesting, but what speciically do you get over vim? I glanced at their comparison page but it looks like they hype a lot of things that you can do with the right vim plugins.

Of course, I imagine vim is more complex to learn (and I am a newbie ).
eschwartz is offline   Reply With Quote
Old 01-01-2015, 03:08 PM   #12
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: 11,460
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by eschwartz View Post
Epsilon sounds interesting, but what speciically do you get over vim? I glanced at their comparison page but it looks like they hype a lot of things that you can do with the right vim plugins.

Of course, I imagine vim is more complex to learn (and I am a newbie ).
Couldn't say. I sort of inherited it, from one of our contractors, and stayed with it. Sort of a "if it ain't broke..." thing.

Hitch
Hitch is offline   Reply With Quote
Old 01-01-2015, 04:48 PM   #13
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,559
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
I used Epsilon on a couple of projects. I (we) liked it because the scripting language is C-like, we were writing our software in C and assembler. It could also emulate Underware Brief which a lot of the programmers had used in previous jobs. As in Hitch's usage, it snuck in via a contractor - it replaced vi, emacs, and Brief.

Bit expensive for personal use though, we had a multi-seat site license.

BR
BetterRed is offline   Reply With Quote
Old 01-01-2015, 05:02 PM   #14
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,229
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by eschwartz View Post
Epsilon sounds interesting, but what speciically do you get over vim? I glanced at their comparison page but it looks like they hype a lot of things that you can do with the right vim plugins.

Of course, I imagine vim is more complex to learn (and I am a newbie ).
Don't go there, please! Warflame between Linux and Windows is sweeter than warflame between vi and emacs
Terisa de morgan is offline   Reply With Quote
Old 01-01-2015, 05:56 PM   #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: 11,460
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by BetterRed View Post
I used Epsilon on a couple of projects. I (we) liked it because the scripting language is C-like, we were writing our software in C and assembler. It could also emulate Underware Brief which a lot of the programmers had used in previous jobs. As in Hitch's usage, it snuck in via a contractor - it replaced vi, emacs, and Brief.

Bit expensive for personal use though, we had a multi-seat site license.

BR
Indeedy, BetterRed! To be clear--I inherited the habit of usage, but not a license--that, I had to pay for. For ALL dem seats, dammit! ;-) And, yes, I like it. It and NoteTab Pro were the two main instigators in me finally breaking down and buying Regex Buddy not only for me, but for those on my crew who were still learning regex-fu. (We have folks that come in, in customer service, who are curious about eBooks, and decide to learn to make them, and thus move over to production from CS. None of them have come equipped regex-ready!)

The divine Terisa de morgan said:

Quote:
Don't go there, please! Warflame between Linux and Windows is sweeter than warflame between vi and emacs
Indeed. No wars here. I have a PC and a Mini-Mac sitting on my desktop (admittedly, I really don't love Macs), and a Linux box sitting next to the desk. My Customer Service Manager, assistant and head whip-cracker, Indy, uses a Linux laptop. We have Win 7, Win 8 and WinXP computers around the shop...we're ominvores.

Hitch
Hitch is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Feature request : using a custom css file Bertrand Writer2ePub 8 12-28-2019 11:46 AM
Combining Class IDs In CSS to Control Left-Indent SeaCanary Sigil 13 02-24-2014 01:58 PM
Extra CSS and class renaming fenuks Recipes 4 01-26-2014 05:24 AM
Feature Request - custom CSS style gentoosiast EPUBReader 1 12-14-2012 03:26 AM
Feature request: CSS style application Fitz Sigil 4 07-25-2010 06:36 AM


All times are GMT -4. The time now is 12:25 AM.


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