| 
			
			 | 
		#1 | 
| 
			
			
			
			 Guru 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 684 
				Karma: 4568205 
				Join Date: Jan 2010 
				Location: Sweden 
				
				
				Device: Kobo Forma 
				
				
				 | 
	
	
	
		
		
			
			 
				
				Horrendous formatting...
			 
			
			
			Bought a new book the other day, and it seems to be some weird fixed layout which makes it impossible to read... 
		
	
		
		
			Every word has it's own set up spans etc... Maybe some of you regex masters can salvage this, I'm actually thinking converting it to pdf and run it through Finereader... ![]() Code: 
	<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops"> <head> <meta charset="utf-8"/> <meta content="width=420,height=595" name="viewport"/> <title>9789137154060-147</title> <link href="css/idGeneratedStyles.css" rel="stylesheet" type="text/css"/> <meta content="urn:uuid:d6736828-9029-46f0-8f4e-838ca7e0a36b" name="Adept.expected.resource"/> </head> <body id="x9789137154060-147" lang="sv-SE" style="width:420px;height:595px" xml:lang="sv-SE"> <div id="_idContainer466"> <img alt="" class="_idGenObjectAttribute-1 _idGenObjectAttribute-2" src="image/1.png"/> </div> <div class="Enkel-textram" id="_idContainer467"> <div style="width:5782.68px;height:589.61px;position:absolute;top:0px;left:0px;-webkit-transform-origin: 0% 0%; -webkit-transform: translate(0px,1px) rotate(0deg) scale(0.05);transform-origin: 0% 0%; transform: translate(0px,1px) rotate(0deg) scale(0.05);"> <p class="Allm-nt-styckeformat ParaOverride-1"><span class="CharOverride-15" id="_idTextSpan32802" style="position:absolute;top:146.54px;left:5516.68px;letter-spacing:-0.63px;">147</span></p> </div> </div> <div id="_idContainer468"> <div style="width:5782.68px;height:9070.87px;position:absolute;top:0px;left:0px;-webkit-transform-origin: 0% 0%; -webkit-transform: translate(0px,1px) rotate(0deg) scale(0.05);transform-origin: 0% 0%; transform: translate(0px,1px) rotate(0deg) scale(0.05);"> <p class="Kapitelnummer ParaOverride-1"><span class="CharOverride-16" id="_idTextSpan32803" style="position:absolute;top:608.94px;left:2380.64px;letter-spacing:0.53px;">KEPITEL 6</span></p> <p class="Kapitelrubrik ParaOverride-1"><span class="CharOverride-17" id="_idTextSpan32804" style="position:absolute;top:1146.1px;left:1647.97px;letter-spacing:-1.61px;">Hoor </span><span class="CharOverride-17" id="_idTextSpan32805" style="position:absolute;top:1146.1px;left:2433.83px;letter-spacing:-1.3px;">möter </span><span class="CharOverride-17" id="_idTextSpan32806" style="position:absolute;top:1146.1px;left:3651.52px;letter-spacing:-2.8px;">doo</span><span class="CharOverride-17" id="_idTextSpan32807" style="position:absolute;top:1606.1px;left:1239.79px;letter-spacing:-3.86px;">oomfärldens </span><span class="CharOverride-17" id="_idTextSpan32808" style="position:absolute;top:1606.1px;left:3504.02px;letter-spacing:-2.54px;">kref?</span></p> <p class="Underrubrik-kapitel ParaOverride-1"><span class="CharOverride-19" id="_idTextSpan32809" style="position:absolute;top:2214.14px;left:1514.99px;letter-spacing:0.68px;">Tre-a </span><span class="CharOverride-19" id="_idTextSpan32810" style="position:absolute;top:2214.14px;left:1870.41px;letter-spacing:5.58px;">sätt </span><span class="CharOverride-19" id="_idTextSpan32811" style="position:absolute;top:2214.14px;left:2287.82px;letter-spacing:5.34px;">itt </span><span class="CharOverride-19" id="_idTextSpan32812" style="position:absolute;top:2214.14px;left:2608.28px;letter-spacing:5.12px;">hoontera </span><span class="CharOverride-19" id="_idTextSpan32813" style="position:absolute;top:2214.14px;left:3388.53px;letter-spacing:5.27px;">ferdegee-a</span></p> <p class="noindent ParaOverride-1"><span class="CharOverride-11" id="_idTextSpan32814" style="position:absolute;top:3420.12px;left:0px;letter-spacing:-0.5px;">Kommer </span><span class="CharOverride-11" id="_idTextSpan32815" style="position:absolute;top:3420.12px;left:839.93px;letter-spacing:-0.39px;">doo </span><span class="CharOverride-11" id="_idTextSpan32816" style="position:absolute;top:3420.12px;left:1122.98px;letter-spacing:-0.47px;">ihåg </span><span class="CharOverride-11" id="_idTextSpan32817" style="position:absolute;top:3420.12px;left:1556.48px;letter-spacing:-0.5px;">testet </span><span class="CharOverride-11" id="_idTextSpan32818" style="position:absolute;top: Code: 
	#_idContainer002 {
	-webkit-transform:translate(-14.174px,-64.257px) rotate(0.000deg) skew(0.000deg) scale(1.000,1.000);
	-webkit-transform-origin:0% 0%;
	height:793.47px;
	left:0px;
	position:absolute;
	top:0px;
	transform:translate(-14.174px,-64.257px) rotate(0.000deg) skew(0.000deg) scale(1.000,1.000);
	transform-origin:0% 0%;
	width:499.95px;
}
span.CharOverride-22 {
	color:#ffffff;
	font-family:"Circular Std Black", sans-serif;
	font-size:220px;
	font-style:normal;
	font-weight:900;
}
div._idGenObjectStyleOverride-1 {
	border-bottom-left-radius:12px;
	border-bottom-right-radius:12px;
	border-style:dotted;
	border-top-left-radius:12px;
	border-top-right-radius:12px;
}
What monstrous program makes this?  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#2 | 
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,784 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			That is a fixed layout ePub. Change the file extention to .kepub.epub and load it on your Forma and it may work. 
		
	
		
		
		
		
		
		
		
		
		
		
	
	Converting to PDF won't work.  | 
| 
		
 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#3 | 
| 
			
			
			
			 Grand Sorcerer 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,269 
				Karma: 16544702 
				Join Date: Sep 2009 
				Location: UK 
				
				
				Device: ClaraHD, Forma, Libra2, Clara2E, LibraCol, PBTouchHD3 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			I think I read somewhere that Kobos expect fixed layout epubs to be named sometitle.fxl.kepub.epub
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#4 | ||
| 
			
			
			
			 Bibliophagist 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 48,175 
				Karma: 174315444 
				Join Date: Jul 2010 
				Location: Vancouver 
				
				
				Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 From the Kobolabs Epub Spec: Quote: 
	
  | 
||
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#5 | 
| 
			
			
			
			 Guru 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 684 
				Karma: 4568205 
				Join Date: Jan 2010 
				Location: Sweden 
				
				
				Device: Kobo Forma 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Yes, as a kepub it's readable on Kobo. 
		
	
		
		
		
		
		
		
		
		
		
		
	
	I would like to convert it to a flowable epub, that's why I thought it may be easier to go via pdf and Finereader, but I may try to play around with regex and see what happens.  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#6 | 
| 
			
			
			
			 Guru 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 684 
				Karma: 4568205 
				Join Date: Jan 2010 
				Location: Sweden 
				
				
				Device: Kobo Forma 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			When I renamed the file to xxx.fxl.kepub.epub it only shows the upper left quadrant of every page. (This was from the kepub-file, maybe it's different from the original epub?)
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#7 | 
| 
			
			
			
			 Bibliophagist 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 48,175 
				Karma: 174315444 
				Join Date: Jul 2010 
				Location: Vancouver 
				
				
				Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Converting a fixed layout epub to reflowable is "fun".  Good luck.
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#8 | |
| 
			
			
			
			 Klak 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 174 
				Karma: 150374 
				Join Date: Sep 2011 
				Location: Belgrade, Serbia 
				
				
				Device: many 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Can you convert it to unicode text and just put some tags around headings? *I visit relatives in Sweden at least once a year (before Corona) for 5 days or a week.  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#9 | 
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,784 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			To keep your sanity, don't try to convert it to reflowable ePub. It's going to be a nightmare at best.
		 
		
	
		
		
		
		
		
		
		
		
		
		
	
	 | 
| 
		
 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#10 | |
| 
			
			
			
			 Bookmaker & Cat Slave 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503 
				Karma: 158448243 
				Join Date: Apr 2010 
				Location: Phoenix, AZ 
				
				
				Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Hitch  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#11 | 
| 
			
			
			
			 Fanatic 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 531 
				Karma: 2268308 
				Join Date: Nov 2015 
				
				
				
				Device: none 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			It should be trivial to simplify the markup with a bit of regexes, as both the paragraph separation and whitespace is present. Locate important formatting like italics, and remove everything else. 
		
	
		
		
		
		
		
		
		
		
		
		
	
	Is the "KEPITEL 6" in your example a typo? Are there any OCR errors?  | 
| 
		
 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#12 | |
| 
			
			
			
			 Bookmaker & Cat Slave 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503 
				Karma: 158448243 
				Join Date: Apr 2010 
				Location: Phoenix, AZ 
				
				
				Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Sarmat can do that for you, easy-peasy. Hitch  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#13 | |
| 
			
			
			
			 Resident Curmudgeon 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 80,784 
				Karma: 150249619 
				Join Date: Nov 2006 
				Location: Roslindale, Massachusetts 
				
				
				Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
  | 
|
| 
		
 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#14 | 
| 
			
			
			
			 Fanatic 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 531 
				Karma: 2268308 
				Join Date: Nov 2015 
				
				
				
				Device: none 
				
				
				 | 
	
	|
| 
		
 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#15 | |
| 
			
			
			
			 Bookmaker & Cat Slave 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503 
				Karma: 158448243 
				Join Date: Apr 2010 
				Location: Phoenix, AZ 
				
				
				Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2 
				
				
				 | 
	
	
	
		
		
		
		
		 Quote: 
	
 Hitch  | 
|
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
![]()  | 
            
        
            
            
  | 
    
			 
			Similar Threads
		 | 
	||||
| 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 07:34 PM | 
| Calibre and FORMATTING how to stop it altering my formatting? | nerys | Calibre | 37 | 07-23-2010 03:35 AM |