![]() |
#1 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
Calibre and FORMATTING how to stop it altering my formatting?
Ok I finally found a good compromise routine.
I want a reader oriented format. ie small text well formated and spaced. but I also love the fast load and "covers" of the LRF format. SO I use some pdf to txt (if its a pdf) to make a txt file I then use notepadd++ to diddle with the formatting to get it "looking" proper for use on the reader. I then import this into calibre let it find the metadata (replacing the cover if its too low res etc.. I just search amazon and usually find something good enough to make 700pixels tall) and export. the problem is Calibre is MESSING with the formatting of my text. how do I stop it from doing this? Some example. ----I will have text set up the way you see me typing it now. If the text is large enough I am just going to type random stuff until its large enough to make my formatting choices clear and make it obvious what I am trying to make my results look like ----Then I want to make sure you understand how I prefer my formatting to look like on the reader etc. I like spaces between my paragraphs while this increase the page count it makes it easier on the eyes to follow the content at least for me it does. ----This way just seems to be easier. When I run this through Claibre I get this ----I will have text set up the way you see me typing it now. If the text is large enough I am just going to type random stuff until its large enough to make my formatting choices clear and make it obvious what I am trying to make my results look like ----Then I want to make sure you understand how I prefer my formatting to look like on the reader etc. I like spaces between my paragraphs while this increase the page count it makes it easier on the eyes to follow the content at least for me it does. ----This way just seems to be easier. which I do not want. How do I stop it from doing that? some things are even more complex than this. For example James Cameron made the Script for Avatar available publicly for anyone to download unencrypted. Conversion to text works quite nicely. a piece looks like this ---------------------------- AVATAR -------------------------- Written by ------------------------James Cameron ALL RIGHTS RESERVED. COPYRIGHT ©2007 TWENTIETH CENTURY FOX FILM CORPORATION. NO PORTION OF THIS SCRIPT MAY BE PERFORMED, PUBLISHED, REPRODUCED, SOLD, OR DISTRIBUTED BY ANY MEANS, OR QUOTED OR PUBLISHED IN ANY MEDIUM, INCLUDING ANY WEB SITE, WITHOUT THE PRIOR WRITTEN CONSENT OF TWENTIETH CENTURY FOX FILM CORPORATION. --THE SOUND OF DRUMS, from a great distance, growing louder. --FADE IN: --WE ARE FLYING through mist, a dimly glimpsed forest below. -------------------- VOICE (V.O.) ---------- When I was lying there in the VA ---------- hospital, with a big hole blown through ---------- the middle of my life, I started having ---------- these dreams of flying. --We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- -------------------- VOICE (V.O.) ---------- Sooner or later though, you always have ---------- to wake up... ------------------------------------------------------ CUT TO: --EXT. CITY - NIGHT --A SCREECH OF BRAKES as a vehicle WIPES FRAME, revealing -- --JAKE SULLY, a scarred and scruffy combat vet, sitting in a beat up carbon-fiber wheelchair. At 22, his eyes are hardened by the wisdom and wariness of one who has endured pain beyond his years. This looks QUITE nice on the reader. alas Calibre mucks it all up and makes it look like this. AVATAR Written by James CameronALL RIGHTS RESERVED. COPYRIGHT �2007 TWENTIETH CENTURY FOX FILM CORPORATION. NO PORTION OF THIS SCRIPT MAY BE PERFORMED, PUBLISHED, REPRODUCED, SOLD, OR DISTRIBUTED BY ANY MEANS, OR QUOTED OR PUBLISHED IN ANY MEDIUM, INCLUDING ANY WEB SITE, WITHOUT THE PRIOR WRITTEN CONSENT OF TWENTIETH CENTURY FOX FILM CORPORATION. --THE SOUND OF DRUMS, from a great distance, growing louder. --FADE IN: --WE ARE FLYING through mist, a dimly glimpsed forest below. --VOICE (V.O.) When I was lying there in the VA hospital, with a big hole blown through the middle of my life, I started having these dreams of flying. --We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- --VOICE (V.O.) Sooner or later though, you always have to wake up... CUT TO: --EXT. CITY - NIGHT --A SCREECH OF BRAKES as a vehicle WIPES FRAME, revealing -- --JAKE SULLY, a scarred and scruffy combat vet, sitting in a beat up carbon-fiber wheelchair. At 22, his eyes are hardened by the wisdom and wariness of one who has endured pain beyond his years. ie it whacks all the formatting. It unreadable like that. how do I make it so I can convert to lrf WITHOUT altering the content of the text file in such a way? IE use it "just" as I give it and just put it in the lrf wrapper with the cover image and metadata? sorry for the dashes but I can not insert tabs and this forum software REMOVES all extraneous spaces. So I replaced the SPACES with DASHES I tried going to the Structure Detection screen and deleting EVERYTHING figuring those were the commands it was using to "redo" the content formatting No joy. it still mucks it all up no apparent change. there IS a check box for remove space between paragraphs which I left BLANK but its still removing the spaces. suggestions? Last edited by nerys; 02-28-2010 at 05:06 PM. |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Use the settings under TXT input to control this.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 | |
US Navy, Retired
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,865
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
2. Go under conversions - Look&feel - and check insert blank line. (this inserts a line between paragraphs). If this doesn't work experiment with other text input settings. |
|
![]() |
![]() |
![]() |
#4 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
there is pretty much NOTHING under txt input
there are 4 checkboxes (all unchecked) Treat each line as a paragraph assume print formatting process using markdown Do not insert table of contents into output text when using markdown. I will try checking each at random and see if anything happens but none of those "jumps out" at me as the source of my problem :-) |
![]() |
![]() |
![]() |
#5 | |
US Navy, Retired
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,865
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
|
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
yeah the manual will help :-) I did read it. Nothing seemed to "apply" to what it was doing.
"I will try checking each at random and see if anything happens but none of those "jumps out" at me as the source of my problem :-)" this comment does not mean I don't know what those things mean. It means I don't see how those things apply to what the program is doing. as expected (assuming they did what they SAID they would do) it had no effect on the output. I tried the treat each line. No appreciable difference. checking the add line between paragraphs does NOT undo the goofy formatting it just add an extra line to the goofy formatting. it seems to be DELETING SPACES ie any extraneous spaces seem to be getting whacked. Notice where it says CUT TO: should be all the way to the right (using spaces) in the txt file the sony reader has no issue with this in the lrf its all gone. Here are 2 pictures. The first one is the LRF output of calibre with BOTH options checked The second picture is the original text file simply viewed by the reader I am also attaching the txt file. Since it was free distributed without an encryption by fox themselves for public consumption I assume this is ok. NOTE if I give calibre a text file and make it into something else and then make it back into a text file I DO NOT GET the same file so it is calibre "changing" things around :-) ie just want to turn all that off. ie make it come out like the second image but as an lrf with a cover. I also tried making both PROFILES "default" (manual says this is good for viewing on computer etc.. I figure maybe that means it won't APPLY changes or something) No joy zero change in output file. Last edited by nerys; 02-28-2010 at 07:33 PM. |
![]() |
![]() |
![]() |
#7 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
Now the Insert blank line SHOULD fix my "normal" novels with no quirky spacing or at least have minimal detrimental effects though I must say its not marked clearly.
Insert Blank Line? what does that mean? it should say insert blank line between each paragraph. but logically if you do not check REMOVE blank line it should "leave" blank lines that are already in place alone. so essentially checking insert blank line is telling the program. yeah you know those lines you just removed? put them back :-) hehe seriously though I can see that being useful if your document does NOT HAVE blank lines between paragraphs so why does calibre remove them if they are present? alas this does not fix files where SPACES are utilized for formatting as calibre seems to remove them all and I am unable to find an option to "tell" it to stop doing that. and you can not use add blank line to fix "fixed width" documents since it won't just add lines between paragraphs it will not add lines between each line as well (which is exactly what it did to this document. if you type a line like this but the screen is half this wide it will "wrap" but if you type a line like this but the screen is half this wide Nothing wraps unless the screen is smaller than your longest line. alas the add blank line takes that and correct adds lines between paragraphs but ALSO adds them like this if you type a line like this but the screen is half this wide See what I mean? the solution is to tell it to STOP altering it :-) ie leaving the line breaks alone leave the spaces and tabs alone JUST convert it. thats what I am trying to do. Last edited by nerys; 02-28-2010 at 07:42 PM. |
![]() |
![]() |
![]() |
#8 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
let me use more examples (this forum also removes the spaces so I have replaced them with --'s
start with this WE ARE FLYING through mist, a dimly glimpsed forest below. -------------------- VOICE (V.O.) ---------- When I was lying there in the VA ---------- hospital, with a big hole blown through ---------- the middle of my life, I started having ---------- these dreams of flying. We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- -------------------- VOICE (V.O.) ---------- Sooner or later though, you always have ---------- to wake up... Now when I run that through calibre it does this WE ARE FLYING through mist, a dimly glimpsed forest below. -------------------- VOICE (V.O.) ---------- When I was lying there in the VA ---------- hospital, with a big hole blown through ---------- the middle of my life, I started having ---------- these dreams of flying. We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- -------------------- VOICE (V.O.) ---------- Sooner or later though, you always have ---------- to wake up... When I tell it to add line space it does NOT put it back the way it was it now does this WE ARE FLYING through mist, a dimly glimpsed forest below. -------------------- VOICE (V.O.) ---------- When I was lying there in the VA ---------- hospital, with a big hole blown through ---------- the middle of my life, I started having ---------- these dreams of flying. We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- -------------------- VOICE (V.O.) ---------- Sooner or later though, you always have ---------- to wake up... worse it also gets rid of all those beginning spaces so you get an unreadable mess :-) WE ARE FLYING through mist, a dimly glimpsed forest below. VOICE (V.O.) When I was lying there in the VA hospital, with a big hole blown through the middle of my life, I started having these dreams of flying. We are very low over the forest now, gliding fast, the drums BUILDING to a PEAK -- VOICE (V.O.) Sooner or later though, you always have to wake up... |
![]() |
![]() |
![]() |
#9 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Sigh you seem to be expecting cailbre to preserve the layout of your text exactly. that's not going to happen. E-book are "reflowable" that means that they are "semantic" not layout oriented.
So a parapgraph in an e-book is represented as <paragraph>some text</paragraph> Not a set of instructions like "leave 3 blank spaces then write the following characters, then change to next line". This is what a TXT file looks like to a computer. calibre's conversion pipeline converts everything into a reflowable format internally, so you are never going to be able to preserve formats that specify exact layouts, like TXT and PDF. |
![]() |
![]() |
![]() |
#10 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
its also what a text file looks like to the SONY.
this has nothing to do about reflow. I don't want calibre to add anything. I just want it to stop REMOVING things :-) take a look at the SECOND image. that is the raw text file (also attached) that the sony is reading just fine. reflow is why I make all paragrahs one big line. so it can "reflow" as needed. a script is a different critter formatting is critical. I am no programmer so I guess its more complicated than I realize but it would seem it should be easy to simply instruct it to STOP doing what its doing. do not "remove" what is already their. I am not asking it to add 6 spaces. I am saying STOP REMOVING the spaces :-) I never asked it to remove the line spaces between paragraphs. you programmed it to do that automatically for some reason. if the layout was incompatible with the reader SURE that would make sense but clearly from the second pic the reader handles it just fine. I don't want it to preseve a layout. Just stop changing it. leave it alone. if its a limitation of LRF ok I guess there is nothing I can do about it. I was kind of hoping there was a check box somewhere that simply did something to the effect of STOP reformatting the content. it seems to me you intentionally (for whatever reason) told the program to take this -------Hello (dashes are spaces) and make it Hello why? why is one space ok but 4 spaces not ok? why does it leave single spaces alone but REMOVE multiple spaces? why does it REMOVE line spaces between paragraphs that are already their? why not leave it alone? is there a technical reason? is there something "I" can do to work around it? ie what can I do to format my documents before I give them to calibre so it stops messing with the formatting? something more compatible with it or something? you tell me and I will do it. I don't mind extra work. Last edited by nerys; 02-28-2010 at 08:08 PM. |
![]() |
![]() |
![]() |
#11 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, it's not easy, in fact it's not possible.
|
![]() |
![]() |
![]() |
#12 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
Well I can see that for some reason I am getting no where and I am just upsetting you. This can not ever have good results so I am just going to drop the issue.
thank you for the reply. |
![]() |
![]() |
![]() |
#13 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
It's that blue face of your, makes my head hurt
![]() To explain a bit more, in a reflowable format, 6 spaces = 1 space and in certain contexts, like the start of a paragraph, is the same as no spaces. |
![]() |
![]() |
![]() |
#14 |
Addict
![]() Posts: 243
Karma: 48
Join Date: Dec 2006
Device: PRS 500 - REB 1200
|
soo what characters should I replace them with to represent spaces?
ie what do I need to do to "end up" with the desired result? I can easily do a global replace and replace twospaces with "some character" and then replace that character with whatever you tell me will result in a similar effect? also how do I stop it from removing the line spaces between paragraphs in the first place? is there some character I can put at each line break so it will LEAVE the space that is already there between paragraphs in place? In html I can "encapsulate" a block of text to instruct the renderer to NOT format the text but leave it as it is. is there something similar I can do here? some <tag> or something I can put at the beginning and end of the file so it encapsulates it "as is" like I can in html? |
![]() |
![]() |
![]() |
#15 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, not with TXT input and not with LRF output. Your best bet is html input and epub output.
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[KOBO] Strip existing formatting to apply my own default formatting to all books | digital_steve | Calibre | 2 | 08-10-2010 06:34 PM |
Calibre formatting help | ohnedla | General Discussions | 1 | 04-14-2010 01:44 PM |
Calibre and FORMATTING how to stop it altering my formatting? | nerys | Calibre | 0 | 02-28-2010 04:51 PM |
Calibre and sony formatting when opening book | motero57 | Calibre | 2 | 01-29-2010 12:24 PM |
line formatting formatting question | daesdaemar | Workshop | 9 | 02-06-2009 11:47 AM |