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 01-30-2013, 11:50 AM   #1
Notjohn
Addict
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 202
Karma: 246332
Join Date: Dec 2012
Device: Kindle
html tidy

As an experiment, I ran an html book through html tidy online. I got one error and 58 "warnings." The Tidy output had incorporated all the warnings.

I then fixed the one error in the original html file and opened it in Sigil. I saved it as filename.epub and clicked on the Tidy icon. (I am using 5.3.) The "validation results" window at the bottom of the page remained blank.

So!

1) Am I correct in assuming that those 58 warnings have all been tidied up without my knowing about it?

2) Is there a chance that Tidy could cause a problem with all that dusting and sweeping behind the scenes?

Thanks!
Notjohn is offline   Reply With Quote
Old 01-30-2013, 12:23 PM   #2
meme
Sigil developer
meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
0.5.3 is a bit old, but if I remember correctly the files were always run through Tidy and therefore would have cleaned up certain types of errors. Full HTML Tidy does change your code some, and if you had certain errors in it it could delete parts - though rare. Pretty Print Tidy only formats and fixes basic issues. But you would have to upgrade to the latest version to have the full options on cleaning.
meme is offline   Reply With Quote
Old 01-30-2013, 12:29 PM   #3
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: 36,203
Karma: 17169472
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Turn Tidy off. It messes with the code in a way that's not acceptable.
JSWolf is offline   Reply With Quote
Old 01-30-2013, 03:01 PM   #4
DaleDe
Grand Sorcerer
DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.
 
DaleDe's Avatar
 
Posts: 9,503
Karma: 4597184
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2
Quote:
Originally Posted by JSWolf View Post
Turn Tidy off. It messes with the code in a way that's not acceptable.
Not acceptable to you I guess but it is acceptable to many folks and certainly to ePubCheck. Quit pushing your agenda on everybody else.

Dale
DaleDe is offline   Reply With Quote
Old 01-30-2013, 03:32 PM   #5
meme
Sigil developer
meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
Pretty Print Tidy makes very few changes to most code, and is the only way at the moment to get the code formatted nicely automatically. In fact, without Pretty Pretty Tidy (with Clean Source set to off), you would be surprised at the number of books that won't open due to errors. At least that's what happened when the setting was defaulted to off for a version. Its really only HTML Tidy that makes, in my view, too many changes - but still some people prefer it so its available for them. Turning Clean Source completely off is certainly possible - and may be useful for those who know exactly how their code is formatted and don't want any changes, which is why its there too.
meme is offline   Reply With Quote
Old 01-30-2013, 06:23 PM   #6
mrmikel
Book Twiddler
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 1,932
Karma: 1405001
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
Clean Source off is primarily useful to books that don't need Sigil in the first place. LOL
mrmikel is offline   Reply With Quote
Old 01-30-2013, 07:18 PM   #7
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: 36,203
Karma: 17169472
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by DaleDe View Post
Not acceptable to you I guess but it is acceptable to many folks and certainly to ePubCheck. Quit pushing your agenda on everybody else.

Dale
We've already had the discussion on the styles (SGC-1, SGC-2, etc) that Tidy can create in the XML files. They are hardly ever the same and if you are trying to do a search/replace to change/fix some code, you may find it doesn't work as expected.

Most people that do dive into the code don't want Tidy making those styles.

http://www.mobileread.com/forums/sho...d.php?t=171931
JSWolf is offline   Reply With Quote
Old 01-30-2013, 07:52 PM   #8
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: 8,762
Karma: 39536849
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by JSWolf
Most people that do dive into the code don't want Tidy making those styles.
Tidy won't make those styles if you know what you're doing (aka: one who dives into the code), and those who don't know what they're doing won't care in the least about those styles. It's a moot point.

Last edited by DiapDealer; 01-30-2013 at 07:54 PM.
DiapDealer is offline   Reply With Quote
Old 01-30-2013, 07:54 PM   #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: 36,203
Karma: 17169472
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Quote:
Originally Posted by DiapDealer View Post
Tidy won't make those styles if you know what you're doing (aka: one who dives into the code), and those who don't know what they're doing won't care in the least about those styles. It's a moot point.
So how do you get Tidy to stop making those styles other then turn it off?
JSWolf is offline   Reply With Quote
Old 01-31-2013, 03:06 AM   #10
meme
Sigil developer
meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
Use Pretty Print Tidy.

Tidy is used for both Pretty Print Tidy and HTML Tidy - but in Pretty Print Tidy the Tidy software is only used to do the most basic cleaning. No styles are created with Pretty Print Tidy.
meme is offline   Reply With Quote
Old 01-31-2013, 05:40 AM   #11
exaltedwombat
Evangelist
exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.
 
Posts: 433
Karma: 1703930
Join Date: Nov 2011
Device: none
Quote:
Originally Posted by meme View Post
Full HTML Tidy does change your code some, and if you had certain errors in it it could delete parts - though rare.
Not that rare in my experience. I class it as a very dangerous function, to be avoided unless you have a special reason - and I can't imagine what that reason could be! The chance of data loss is a pretty negative feature.
On a related point, we still badly need a 'save it as it is - I'll fix the errors later' option. Sometimes an editing session has to end NOW.
exaltedwombat is offline   Reply With Quote
Old 01-31-2013, 06:50 AM   #12
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: 8,762
Karma: 39536849
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Allowing to save an epub in an invalid state means Sigil would have to allow opening an epub in an invalid state. How would Sigil possibly know that the error is one that you intentionally saved it with and not one that it would normally fix? The only way I could see that working is by saving it as some other file-type; which is likely to cause confusion when people don't know that they need to open the new error-state-saved project file in order to pick up where they left off. I just don't see it happening.
DiapDealer is offline   Reply With Quote
Old 01-31-2013, 08:04 AM   #13
exaltedwombat
Evangelist
exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.
 
Posts: 433
Karma: 1703930
Join Date: Nov 2011
Device: none
Quote:
Originally Posted by DiapDealer View Post
Allowing to save an epub in an invalid state means Sigil would have to allow opening an epub in an invalid state. How would Sigil possibly know that the error is one that you intentionally saved it with and not one that it would normally fix? The only way I could see that working is by saving it as some other file-type; which is likely to cause confusion when people don't know that they need to open the new error-state-saved project file in order to pick up where they left off. I just don't see it happening.
It's better than being in a position where you've broken something, don't quickly see the error, can't save but have to end the editing session and be somewhere else! Auto-fix can lose data.
exaltedwombat is offline   Reply With Quote
Old 01-31-2013, 08:50 AM   #14
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: 8,762
Karma: 39536849
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I'm not saying it wouldn't be handy. I'm saying I don't think the way Sigil's currently structured will easily allow that kind of "anything goes" save/open scenario. The vast majority of Sigil's feature set is predicated on xhtml being well-formed to begin with.

As I said, the only way I see around it is saving epubs in invalid states as a different filetype. Which while feasible, comes with it's own headaches and considerations. There simply is no "just save it as it is" solution to the problem. Never has been. It would be implemented already if there were.
DiapDealer is offline   Reply With Quote
Old 01-31-2013, 08:57 AM   #15
Notjohn
Addict
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 202
Karma: 246332
Join Date: Dec 2012
Device: Kindle
Back up! Back up! You're arguing in the corner office while out here in the cubicles I don't know what you're talking about.

Which version of Tidy is in Sigil?

I went to http://infohound.net/tidy/ and got what I assume is the "full" HTML Tidy that makes changes without being consulted, is that right?

I don't find any Pretty Tidy (I get some pictures of tidy places!) but I do find Pretty Print at http://xmlprettyprint.com/ -- is that what I'm after?

And are you saying that if I go to another cubicle and use Sigil 6.x, I will have control over what the built-in Tidy does?
Notjohn is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Please turn Tidy off by default JSWolf Sigil 75 05-13-2012 11:03 AM
Tidy use and issue DaleDe Sigil 7 06-19-2011 07:22 PM
Love Sigil, Hate HTML Tidy Danger Sigil 2 12-25-2010 08:00 PM
Sigil, HTML Tidy or PEBCAK? DTM Sigil 6 09-26-2010 08:49 PM
HTML Tidy problems pdurrant Sigil 2 04-08-2010 07:38 AM


All times are GMT -4. The time now is 02:45 PM.


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