Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old Yesterday, 01:39 AM   #31
Comfy.n
want to learn what I want
Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.
 
Posts: 1,173
Karma: 6426808
Join Date: Sep 2020
Device: Calibre E-book viewer
Quote:
Originally Posted by DNSB View Post
Tried that once & it took me hours to get down from the ceiling. Never again!


Quote:
Originally Posted by foosion View Post
A nice way to see the list is to execute in Python

Code:
import this
Of course, the best import to execute in Python is

Code:
import antigravity
Both imports are entertaining although I despise myself for taking too much time trying to find out the truth about who's the dutch in 'Although that way may not be obvious at first unless you're Dutch.'

https://softwareengineering.stackexc...ce-to-dijkstra
Comfy.n is offline   Reply With Quote
Old Yesterday, 07:59 AM   #32
foosion
Addict
foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.
 
Posts: 386
Karma: 41524
Join Date: Sep 2011
Device: Kobo Libra 2 & Clara BW
Quote:
Originally Posted by DNSB View Post
Tried that once & it took me hours to get down from the ceiling. Never again!
Compare Mary Poppins' Uncle Albert.

Quote:
Originally Posted by Comfy.n View Post
Both imports are entertaining although I despise myself for taking too much time trying to find out the truth about who's the dutch in 'Although that way may not be obvious at first unless you're Dutch.'

https://softwareengineering.stackexc...ce-to-dijkstra
Interesting. I always assumed it was Guido, since he created Python, although I never checked.
foosion is offline   Reply With Quote
Old Yesterday, 08:12 AM   #33
Comfy.n
want to learn what I want
Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.
 
Posts: 1,173
Karma: 6426808
Join Date: Sep 2020
Device: Calibre E-book viewer
Actually there's a confirmation by Tim Peters himself (author of the Zen statements) in that same answer. It was about Guido, but I had to confirm, grr.
Comfy.n is offline   Reply With Quote
Old Yesterday, 11:45 AM   #34
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: 75,981
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by foosion View Post
For today's crappy code, a book with style="whatever" littered throughout the text. If every h2 is <h2 style="text-align: center";>, which not just put that in the CSS?? Similarly for many other tags.

Probably a rhetorical question.
I've seen code such as <p class="para" style="text-align: 0%;">. And there is a CSS file.
JSWolf is offline   Reply With Quote
Old Yesterday, 11:47 AM   #35
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: 75,981
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by foosion View Post
One issue with <p> is distinguishing paragraphs with a text-indent and those without. Some CSS defines <p> with a text-indent and then has a class="noindent", typically for the first paragraph of a section, while others define <p> without an indent, then add a class="indent" for every paragraph other than the first.

Is one of these more canonical?
I prefer <p> for the majority of paragraphs and <p class="someclass"> when I want to deviate from the majority of paragraph styles. And I do prefer to have the indent in p in the CSS.

One thing that means doing is putting a text-indent: 0; in most/all classes that have a text-align: center; because most eBooks do not put an indent with p.
JSWolf is offline   Reply With Quote
Old Yesterday, 01:17 PM   #36
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,534
Karma: 19000001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Depending on how complex the book is, you may get away using only <p> and styling p and h1+p (or whatever h level you use for chapter headings).

I'd use some class name other than "noindent", something like "first" and/or "continued". Just to maintain the distinction between semantics and styling. Those paragraphs are unindented because they have some feature, not because I randomly decided to disable indent for them. If some day I want to also indent the first paragraph in a chapter (as is done in other language traditions, by the way), I won't feel embarrassed by adding some indent to the "noindent" class.
Jellby is offline   Reply With Quote
Old Yesterday, 01:29 PM   #37
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: 75,981
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Jellby View Post
Depending on how complex the book is, you may get away using only <p> and styling p and h1+p (or whatever h level you use for chapter headings).

I'd use some class name other than "noindent", something like "first" and/or "continued". Just to maintain the distinction between semantics and styling. Those paragraphs are unindented because they have some feature, not because I randomly decided to disable indent for them. If some day I want to also indent the first paragraph in a chapter (as is done in other language traditions, by the way), I won't feel embarrassed by adding some indent to the "noindent" class.
I do use an <hr/> for the section breaks. So the next <p> is styled for no indent with hr + p.

I probably should also do an h2 + p for no indent as I mostly use <h2> for the chapter header.
JSWolf is offline   Reply With Quote
Old Yesterday, 02:37 PM   #38
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,197
Karma: 18843349
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by JSWolf View Post
I do use an <hr/> for the section breaks. So the next <p> is styled for no indent with hr + p.


Quote:
Originally Posted by JSWolf View Post
I probably should also do an h2 + p for no indent as I mostly use <h2> for the chapter header.
I agree with your first example because there's really no definition of the-first-paragraph-that-follows-a-section-break... but I would actually define the first paragraph in the chapter as <p class="first"> or <p class="CO"> (chapter opener) instead.

Code:
<h2>Chapter Title</h2>
<p class="first">Yadda yadda yadda.</p>
Then you can apply whatever styles you want to that particular class, not just no-indent. You can even easily set the css to do any number of things depending on your creativity and the capabilities of your device.

Code:
p.first {}
p.first::first-letter {}
p.first::first-line {}
...
...
...
You can even set that css to be responsive and compatible with all kinds of different devices/apps based on screen size, @media, @supports, backwards compatibility for ePub2, as well as all the fun/creative things that are possible JUST because you semantically defined the first paragraph.

And here is the part that you like best, Jon. You can leave it a plane, vanilla no-indent while still having it set semantically. It's a win-win!!
Turtle91 is offline   Reply With Quote
Old Today, 09:24 AM   #39
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: 75,981
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Turtle91 View Post




I agree with your first example because there's really no definition of the-first-paragraph-that-follows-a-section-break... but I would actually define the first paragraph in the chapter as <p class="first"> or <p class="CO"> (chapter opener) instead.

Code:
<h2>Chapter Title</h2>
<p class="first">Yadda yadda yadda.</p>
Then you can apply whatever styles you want to that particular class, not just no-indent. You can even easily set the css to do any number of things depending on your creativity and the capabilities of your device.

Code:
p.first {}
p.first::first-letter {}
p.first::first-line {}
...
...
...
You can even set that css to be responsive and compatible with all kinds of different devices/apps based on screen size, @media, @supports, backwards compatibility for ePub2, as well as all the fun/creative things that are possible JUST because you semantically defined the first paragraph.

And here is the part that you like best, Jon. You can leave it a plane, vanilla no-indent while still having it set semantically. It's a win-win!!
I don't need a class as I can style h2 + p as needed.

Personally, I prefer not to use first. I don't like dropcaps or large first letter or smallcaps, etc. I just like normal text unless there's a reason for a style.
JSWolf is offline   Reply With Quote
Old Today, 10:35 AM   #40
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,197
Karma: 18843349
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by JSWolf View Post
Personally, I prefer not to use first. I don't like dropcaps or large first letter or smallcaps, etc. I just like normal text unless there's a reason for a style.
You certainly can do it that way, and that is what I was referring to when I mentioned you can be as creative or plain/vanilla as you want.


Quote:
Originally Posted by JSWolf View Post
I don't need a class as I can style h2 + p as needed.
Yes, you can do it this way as well, but it makes the css a bit more unruly. Which do you think is cleaner?

Code:
h2 + p  {}
h2 + p::first-letter {}
h2 + p::first-line {}

-OR-

p.first  {}
p.first::first-letter {}
p.first::first-line {}
Also, you need to consider that there are a lot of books out there that have something inserted between the chapter head and the first paragraph, so a simple h2 + p doesn't work. Whereas, if you get in the habit of semantically labeling the first paragraph, your styling of choice will be appropriately rendered regardless of any intervening elements. Here are a couple of examples:

Click image for larger version

Name:	Screenshot 2024-10-04 101603.png
Views:	16
Size:	172.7 KB
ID:	211193

Click image for larger version

Name:	Screenshot 2024-10-04 101239.png
Views:	19
Size:	456.3 KB
ID:	211194

Click image for larger version

Name:	Screenshot 2024-10-04 101102.png
Views:	17
Size:	457.8 KB
ID:	211195

Quiz Time!
Can you name the Book/Author from the images above? (no cheating)
Spoiler:

image 1: The Long Earth by Terry Pratchett and Stephen Baxter

image 2: The Dragon Reborn by Robert Jordan

image 3: Dune by Frank Herbert
Turtle91 is offline   Reply With Quote
Old Today, 10:58 AM   #41
foosion
Addict
foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.foosion is an enigma wrapped up in a mystery.
 
Posts: 386
Karma: 41524
Join Date: Sep 2011
Device: Kobo Libra 2 & Clara BW
Quote:
Originally Posted by Turtle91 View Post
Quiz Time!
Can you name the Book/Author from the images above? (no cheating)
Spoiler:

image 1: The Long Earth by Terry Pratchett and Stephen Baxter

image 2: The Dragon Reborn by Robert Jordan

image 3: Dune by Frank Herbert
I don't remember ever seeing 1 & 2, let alone reading them, so no. I have heard of two of the three authors.

3: I've read that enough times to identify immediately.
foosion is offline   Reply With Quote
Old Today, 02:47 PM   #42
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 39,693
Karma: 154147704
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
I've spoilered my reply since I included book titles.

Spoiler:
I recognize 1 from The Long Earth by Terry Pratchett and Stephen Baxter
3 from Dune by Frank Herbert
but other than saying 2 is by Robert Jordan's Wheel of Time series, no idea as to book title.

Last edited by DNSB; Today at 02:50 PM.
DNSB is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Line height issue Mercador Kobo Reader 19 07-21-2020 02:32 PM
CSS line height vs Kobo line spacing slider? bongoman Kobo Reader 2 07-12-2020 01:25 PM
line height Rellwood Conversion 3 04-07-2018 04:34 AM
Aura H2O Line height setting is ignored kAlvaro Kobo Reader 6 08-09-2016 07:59 AM
Line spacing confusion Wrongway Kobo Reader 3 04-05-2014 07:23 AM


All times are GMT -4. The time now is 06:20 PM.


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