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 10-06-2021, 05:14 AM   #1
FrankJH
Member
FrankJH began at the beginning.
 
Posts: 22
Karma: 10
Join Date: Oct 2021
Location: Stuttgart, Germany
Device: Galaxy Tab S7+
Sigil: CSS problem

Dear all,

I'm relatively new to ebook creation, so I hope it's ok if I ask this question here ... I did a lot of google research in the last days, but have not found any useful solutions so far ...

Recently, I updated my operating system from SuSe Leap 15.1 to 15.2, then to SuSe Leap 15.3 - there is Sigil 1.2.1 now.

When I open my ebook, the preview doesn't apply my stylesheet settings any more.

Furthermore, it seems as if the stylesheet I use in this ebook is completely ignored.

What's curious: in my recent version on SuSe Leap 15.1, all worked fine.

I read in this forum that there were similar problems with the newest version sometimes .. but 1.2.1 is not the newest version, it is 1.7.0 in the meantime ...

Any ideas how I can get my stylesheet work again?

Kind regard, and thanks a lot for your efforts, Frank
FrankJH is offline   Reply With Quote
Old 10-06-2021, 05:24 AM   #2
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,093
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Welcome to MR!!

There are a few reasons this could be happening. Taking the risk of sounding like an IT troubleshooting rep, and not intending to imply anything bad: The first step is ensuring you have the CSS stylesheet linked to the html document properly.

- right click on the html document(s) and select link stylesheet
- select the stylesheet(s) you wish to link


Sometimes Sigil will expect to find resources (CSS, Images, Fonts) in a location that differs from the actual ePub - or from where the link says they are located. Using the above steps fixes most of that. The next step - which I use most of the time - is to reorganize those resources into a standard file structure by selecting that from the tools menu.

If that doesn't work, then let us know and we can start looking at some other options.

Cheers!
Turtle91 is offline   Reply With Quote
Advert
Old 10-06-2021, 05:51 AM   #3
FrankJH
Member
FrankJH began at the beginning.
 
Posts: 22
Karma: 10
Join Date: Oct 2021
Location: Stuttgart, Germany
Device: Galaxy Tab S7+
Thanks for your fast reply, and for your "Welcome" too

I read about similar problems here, and that

>> - right click on the html document(s) and select link stylesheet

was what I tried ... without any effect.

>> The next step - which I use most of the time - is to reorganize those resources into a standard file

You mean "Tools -> Restructure Epub to Sigil norm"?

That's what I tried too ... without any effect.

I read here in the forum that similar things happened to some people who updated their Sigil version ... my previous version must have been 0.9.x or so, and the stylesheet was working in the preview ...

Some people wrote about some changes in the epub structure since Sigil 1.x or so ... it must have to do with this, but I have no idea how to solve this ...

Best wishes, Frank
FrankJH is offline   Reply With Quote
Old 10-06-2021, 06:42 AM   #4
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: 27,539
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
If you updated from Sigil 0.9.x to Sigil 1.2.1, there's a few new python modules that are mandatory for Sigil to function properly. One of those modules is the css-parser module. Unfortunately, not all Linux distros are great at picking up on these python requirement changes. It's been a while since I've used SuSe, so I don't know the particulars of installing python modules from Suse repos, but the package should be called something like python-css-parser

The dulwich module also became mandatory (for Sigil's checkpointing feature), so you may want to make sire that's installed as well. Unfortunately, it looks like the version in the SuSe 15.3 repos is quite old (0.18.x). You'll probably want to use pip install to get a version 0.19 or newer.

If that's not the issue, then we'll probably need to see some actual epub samples to see what's going on. Just remember not to attach any copyrighted epubs if you decide to go that route.

Last edited by DiapDealer; 10-06-2021 at 06:54 AM.
DiapDealer is online now   Reply With Quote
Old 10-06-2021, 08:48 AM   #5
FrankJH
Member
FrankJH began at the beginning.
 
Posts: 22
Karma: 10
Join Date: Oct 2021
Location: Stuttgart, Germany
Device: Galaxy Tab S7+
Thanks for your offer.

Maybe sometimes it's not the best idea to update an existing system ... I'm not so familar with updating python modules, maybe the problem is located elsewhere, maybe my mistake ... otherwise I have to consider a complete new installation of the software ...

To see the problem, I created a simple new epub called "sample.epub".

I use my original stylesheet and linked it ... a span class "bluebold" (see below) is defined in the styleheet, but the formatting

span.bluebold {
color: #0066cc;
font-weight: bold;
}

won't appear in the preview - any idea what could be the cause?

Best wishes, Frank

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops">
<head>
<title></title>
<link href="../Styles/sgc-nav.css" type="text/css" rel="stylesheet"/>
</head>

<body>
<p>saasa</p>
<span class="bluebold">Some Text</span>
</body>
</html>
Attached Files
File Type: epub sample.epub (3.2 KB, 112 views)
FrankJH is offline   Reply With Quote
Advert
Old 10-06-2021, 09:11 AM   #6
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: 27,539
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
There's a syntax error in your css file at line 208, but that shouldn't make Preview ignore the entire css file (but any ADE-based rendering engines probably will). It doesn't with the latest version of Sigil on Windows or Linux, anyway.

span.boldspan. shouldn't have the period at the end.

Quote:
Originally Posted by FrankJH View Post
I read in this forum that there were similar problems with the newest version sometimes .. but 1.2.1 is not the newest version, it is 1.7.0 in the meantime ...
I'm unaware of any issues with the newest version of Sigil properly displaying css. Can you point to some of the threads/posts you found in the forum that suggested otherwise? Maybe something there will shed some light on the problem.

Last edited by DiapDealer; 10-06-2021 at 09:45 AM.
DiapDealer is online now   Reply With Quote
Old 10-06-2021, 09:44 AM   #7
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,605
Karma: 5433388
Join Date: Nov 2009
Device: many
FWIW, I did see this in the Bugs Fixed for Sigil-1.3.0,

- Fix bug that prevented css updates from being shown in Preview without reload

Not sure if that old bug is the culprit or not.

Sigil 1.2.1 is a very old version of Sigil.
KevinH is online now   Reply With Quote
Old 10-06-2021, 09:48 AM   #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: 27,539
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I got the impression that the OP was opening existing epubs that worked with older versions of Sigil/OS. If that's not the case, simply saving the epub and re-opening it should determine if that bug is the culprit, no?
DiapDealer is online now   Reply With Quote
Old 10-06-2021, 09:58 AM   #9
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,605
Karma: 5433388
Join Date: Nov 2009
Device: many
Yes. Correct. That old bug was from editing changes in css tab not showing up in Preview until that page that used it was reloaded.
KevinH is online now   Reply With Quote
Old 10-06-2021, 10:27 AM   #10
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: 27,539
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Well it looks like openSUSE Leap 15.3 DOES install all of the necessary python dependencies, so it's not that. Still finishing up getting a VM set up to test their repo version of Sigil-1.2.1.
DiapDealer is online now   Reply With Quote
Old 10-06-2021, 10:47 AM   #11
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,605
Karma: 5433388
Join Date: Nov 2009
Device: many
I have tested the sample.epub (after fixing the extra . typo in the css stylesheet) on macOSX with Sigil 1.7, 1.6, 1.5.1, 1.4.3, 1.30, and 1.2.0 (1.2.1 was a linux only source release) and it always shows the text on opening in blue bold.

So whatever the issue is, it is Linux specific and maybe even SuSE specific. My quess is it is QtWebEngine related.

If it worked on SuSE Leap 15.1, what version of Sigil was that? Could this be related to the move from QtWebKit to QtWebEngine after Sigil-0.9.14?
KevinH is online now   Reply With Quote
Old 10-06-2021, 11:16 AM   #12
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,093
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by FrankJH View Post
Thanks for your offer.

Maybe sometimes it's not the best idea to update an existing system ... I'm not so familar with updating python modules, maybe the problem is located elsewhere, maybe my mistake ... otherwise I have to consider a complete new installation of the software ...

To see the problem, I created a simple new epub called "sample.epub".

I use my original stylesheet and linked it ... a span class "bluebold" (see below) is defined in the styleheet, but the formatting

span.bluebold {
color: #0066cc;
font-weight: bold;
}

won't appear in the preview - any idea what could be the cause?

Best wishes, Frank

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops">
<head>
<title></title>
<link href="../Styles/sgc-nav.css" type="text/css" rel="stylesheet"/>
</head>

<body>
<p>saasa</p>
<span class="bluebold">Some Text</span>
</body>
</html>
I'm not saying this is the cause of your problem, but just something I noticed.

Usually a span will be inside a block element:

Code:
<p><span class="bluebold">Some Text</span></p>
edit:
It does work...just not normal... and I understand it is just a sample.
Regardless - it also previews properly on my windows10 x64

Last edited by Turtle91; 10-06-2021 at 11:26 AM.
Turtle91 is offline   Reply With Quote
Old 10-06-2021, 11:20 AM   #13
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,605
Karma: 5433388
Join Date: Nov 2009
Device: many
Based on a quick websearch OpenSuSE Leap 15.1 used a very old Sigil 0.9.10.

The OP may want that older version if they need to use BookView style editing.
KevinH is online now   Reply With Quote
Old 10-06-2021, 11:32 AM   #14
FrankJH
Member
FrankJH began at the beginning.
 
Posts: 22
Karma: 10
Join Date: Oct 2021
Location: Stuttgart, Germany
Device: Galaxy Tab S7+
Yes, the "." in my css was not correct ...

I can't remember my Sigil version on 15.1 ... but it must be related to Qt ...

My idea was to install a newer version of SIgil, so I downloaded 1.4.3 and 1.7.0 ...

As described, I executed

cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release ../Sigil-1.7.0

and received the errors below in both cases:


CMake Error at src/CMakeLists.txt:800 (add_executable):
Target "sigil" links to target "Qt5::PrintSupport" but the target was not
found. Perhaps a find_package() call is missing for an IMPORTED target, or
an ALIAS target is missing?


CMake Error at src/CMakeLists.txt:800 (add_executable):
Target "sigil" links to target "Qt5::WebEngine" but the target was not
found. Perhaps a find_package() call is missing for an IMPORTED target, or
an ALIAS target is missing?


CMake Error at src/CMakeLists.txt:800 (add_executable):
Target "sigil" links to target "Qt5::WebEngineWidgets" but the target was
not found. Perhaps a find_package() call is missing for an IMPORTED
target, or an ALIAS target is missing?


CMake Error at src/CMakeLists.txt:800 (add_executable):
Target "sigil" links to target "Qt5::Network" but the target was not found.
Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?


CMake Error at src/CMakeLists.txt:800 (add_executable):
Target "sigil" links to target "Qt5::Concurrent" but the target was not
found. Perhaps a find_package() call is missing for an IMPORTED target, or
an ALIAS target is missing?
FrankJH is offline   Reply With Quote
Old 10-06-2021, 11:34 AM   #15
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: 27,539
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Well I set up an openSUSE VM and I can confirm that all css is being flat-ass ignored using their repo version of Sigil 1.2.1! We obviously can't go back in time and fix the 1.2.1 version of Sigil, but when I get some time, I'll see if I can figure out why it's happening, and if there might be some kind of workaround for it.

I saw at least one Qt 5.12.x version flying by, so it shouldn't be an issue of too old a Qt/QtWebEngine.
DiapDealer is online now   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
Sigil 0.9.x CSS refresh problem Sinom Bre Sigil 32 02-23-2016 03:52 AM
Sigil 0.6.0 & CSS problem? michaelbr Sigil 2 11-21-2012 08:38 PM
Sigil UI and the CSS Artha Sigil 2 11-22-2011 02:22 PM
Sigil 0.3.4 / Problème CSS entre Sigil et iPad Grivels Software 10 07-03-2011 09:06 AM
Sigil styles and CSS View[+]Finder Sigil 4 05-27-2010 05:39 PM


All times are GMT -4. The time now is 04:11 PM.


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