|
|||||||
![]() |
|
|
Thread Tools | Search this Thread |
|
|
#1 |
|
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Mar 2024
Device: Kobo Libra 2
|
Stylesheet/CSS syntax highlighting: green text for invalid properties?
Hello,
I am editing an ebook with Calibre and have a question regarding the syntax highlighting of CSS code / stylesheets. Properties are usually highlighted with blue text, but some are displayed with green text. For example: Code:
.box {
margin-top: 1.5em;
margin-bottom: 1.5em;
word-wrap: break-word;
}
Maybe the properties highlighted in green are invalid/unsupported for epub files? Or is it because of a CSS version difference? The property does exist and works fine, even in the Calibre editor preview. Thanks! |
|
|
|
|
|
#2 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,739
Karma: 9501032
Join Date: Sep 2021
Location: Australia
Device: Kobo Libra 2
|
I thought word-wrap was deprecated or non-standard.
Try overflow-wrap... https://developer.mozilla.org/en-US/.../overflow-wrap You can also use <wbr/> and insert that where you want the break to occur. eg... This<wbr/>isa<wbr/>long<wbr/>sentence |
|
|
|
| Advert | |
|
|
|
|
#3 | |
|
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 81,527
Karma: 150265873
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
|
|
|
|
|
#4 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,837
Karma: 28586150
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
word-wrap is deprecated and non-standard. Use overflow-wrap
|
|
|
|
|
|
#5 |
|
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Mar 2024
Device: Kobo Libra 2
|
Thank you all, I will use overflow-wrap instead.
But word-wrap was only an example and my question is rather what the green highlighting's meaning is. |
|
|
|
| Advert | |
|
|
|
|
#6 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,837
Karma: 28586150
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
It's meaning in that context is its not a recognized property name
|
|
|
|
![]() |
| Tags |
| css, stylesheet, syntax |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Code syntax highlighting | banana8281982 | Editor | 3 | 07-25-2024 11:48 AM |
| pagestyle.css extra / integrated in stylesheet.css / or not at all? | chaot | Workshop | 14 | 02-25-2017 12:10 AM |
| Missing CSS properties | roger64 | KOReader | 0 | 06-01-2016 07:39 AM |
| Syntax Highlighting extra feature | jackie_w | Editor | 4 | 12-23-2013 04:33 AM |
| Invalid Syntax Error | msprang | Sony Reader | 7 | 11-07-2009 02:11 PM |