elf: Quote: She is too fond of books, and it has turned her brain (Fond of Books)
elf ([personal profile] elf) wrote in [community profile] ebooks2010-11-09 07:46 am

The Random Ebooks Questions Post

Ask your questions! Get answers! Maybe even useful answers!

Ask anything! Ask about ereaders, or filetypes, or conversion methods, or where to find books, or which authors don't like ebooks, or what software works on which computers, or anything else ebook-related. Preferably, put the question, or part of it, in the subject line. That way, the questions will be easy to find, and new readers who show up can see if their question has been asked before.

Feel free to post links to your journal where you've spelled out your questions in detail (or just make a new post here; it's totally fine to make a long post about "thinking about ebook readers; what's the pros & cons of these two?")

Answer questions! If you know about a certain aspect of ebookery, jump in with answers!
jumpuphigh: Pigeon with text "jumpuphigh" (Default)

Re: AO3 bug with epub files?

[personal profile] jumpuphigh 2010-11-09 07:24 pm (UTC)(link)
I wonder if I should just automatically run every book through calibre's convert process before loading. If I just make it a habit, it won't take more than a few seconds to do that.

lady_krysis: cropped photo of a young woman wearing a blue tank dress laying in the grass, holding a violin (feeling the music)

Re: AO3 bug with epub files?

[personal profile] lady_krysis 2010-11-09 07:29 pm (UTC)(link)
Hmmm. I'm thinking I might just do this, too.
amalthia: (Default)

Re: AO3 bug with epub files?

[personal profile] amalthia 2010-11-10 04:31 am (UTC)(link)
I run all the A03 fics through an epub conversion but honestly it's just so I can add this css override code to the epubs.

body { margin: 0; }
a {text-decoration: none; color: black;}
a [href] {text-decoration: none; color: black;}
p {margin-top: 0pt; margin-bottom: 0pt; padding: 0pt; text-indent: 15pt; text-align: justify;}
h1 { text-align: center;}
h2 {text-align: center; }
h3 { text-align: center;}
h4 { text-align: center; }
h5 { text-align: center; }
h6 { text-align: center; }
valiha: watercolor painting of my cat Lola (Default)

Re: AO3 bug with epub files?

[personal profile] valiha 2010-11-26 10:27 am (UTC)(link)
I think you can shorten your css by combining the header declarations: h1, h2, h3, h4, h5, h6 {text-align: center} since they're all the same.

And I might be wrong, but I don't think you need the semi-colon if you have only one item.
amalthia: (Default)

Re: AO3 bug with epub files?

[personal profile] amalthia 2010-11-26 10:37 am (UTC)(link)
Good tip. :) I'll have to try it out. So far I haven't really had to worry about length because that code is the default. But it is good to know that I can merge the headings tags into one line.

I'll look into the semi-colon use. I'm not exactly sure what you mean about having only one item? But what I pasted here is generally what I use on every story I convert and the output comes out like I expect. I suspect there is some wiggle room for error though.
valiha: watercolor painting of my cat Lola (Default)

Re: AO3 bug with epub files?

[personal profile] valiha 2010-11-26 11:06 am (UTC)(link)
I meant text-align: center; as one item - I can't remember what it's called at the moment (declaration??), sorry! Obviously, if you want to style several things about your header, you'll use the semi-colon between them. And yes, you can combine several things if you want to style them the same way, just add a comma in between.

Say you want all the headers to be centered, but only h1 to have a bottom border and to be in uppercase.

h1, h2, h3, h4, h5, h6 {text-align: center}
h1 {border-bottom: solid 1px; text-transform: uppercase}

(Gosh, this makes me look like I'm presenting myself as some sort of an experts, which is so far from the truth!)
Edited 2010-11-26 11:08 (UTC)
valiha: watercolor painting of my cat Lola (Default)

Re: AO3 bug with epub files?

[personal profile] valiha 2010-11-26 11:36 pm (UTC)(link)
Baby-steps, and hand holding, which is what I got at [livejournal.com profile] s2smoothsailing when I was tweaking my LJ layout. They taught me how to have bullets - actual small bullets - show up when hovering over the header navigation [mine is a Western fandom :) ].

I really enjoy css, and whenever I'm afraid to change something, I just make a copy of the files involved - that way I don't risk the originals. I don't remember seeing css tutorials at mobileread; is there a forum or were these snippets mostly offers from other members?
amalthia: (Default)

Re: AO3 bug with epub files?

[personal profile] amalthia 2010-11-26 10:58 pm (UTC)(link)
I love to learn more and truly I had no clue you could add all the heading tags in one line. All the previous examples I saw online split them up.

I'm thinking to merge h4-h6 into one line since I rarely add anything extra besides centering those headers. It does save space and makes it easier to read the code.

I've been mostly teaching myself css and using the online tutorials but finding best practices and more efficient ways to accomplish the same thing is a bit harder to figure out.
valiha: watercolor painting of my cat Lola (Default)

Re: AO3 bug with epub files?

[personal profile] valiha 2010-11-26 11:29 pm (UTC)(link)
Just have in mind that if you want all of them to be centered, then all should be combined. Then you can "cascade down" and specify the style for only some elements:

All should be centered = h1, h2, h3, h4, h5, h6 {text-align: center}
The first three should be centered + uppercase = h1, h2, h3 {text-transform: uppercase}
The first one should be centered + uppercase + have a bottom border = h1 {border-bottom: solid 1px}

The styles listed first are general, and get more specific the lower you go. The general styles are applied to all the elements unless you override them; so if you don't want h4-6 to be centered, you can leave them out of the first declaration, or override it by adding one more line after h1:

h4, h5, h6 {text-align: left}

I mostly used online tutorials too, but the people at LJ's Smooth Sailing Layout comm helped me a lot while I was modifying my layout. It makes a huge difference when you can ask someone to walk you through the reasons why something is just so. The Web Developer addon for Firefox is priceless too.
amalthia: (Default)

Re: AO3 bug with epub files?

[personal profile] amalthia 2010-11-26 11:37 pm (UTC)(link)
Most of my css help has come from the Mobile Read forums. :) I'm going to have to find this web developer addon and check out the LJ smooth sailing layout comm. :)

You're right it does help to have someone to help explain things because the tutorials don't always go into great depth as to why css works a certain way and piecing it all together is not easy.
valiha: watercolor painting of my cat Lola (Default)

Re: AO3 bug with epub files?

[personal profile] valiha 2010-11-26 11:46 pm (UTC)(link)
Link to Smooth Sailing in an entry above, and Web Developer here! Once added to Firefox, you just click on CSS, then on View style information, then hover over an element on the page. When you click on that, an information window at the bottom of the browser shows you all the details about what css was used for which page element.
amalthia: (Default)

Re: AO3 bug with epub files?

[personal profile] amalthia 2010-11-26 11:52 pm (UTC)(link)
Thanks! This sounds incredibly useful. :)