Quick BBCode Update · 11:38pm
I just wanted to make a quick blog post on this change I made earlier so people know what's causing any bugs.
I've changed the way our text/bbcode parser handles new lines and indents. For those interested in the code side, the old system generated a <br /> for each new line, and indents were super hackily done by addition a 3.0em wide floating div. It worked, but it wasn't particularly valid. So I've changed it now to make proper use of paragraphing and css indenting. Basically this means that the indents ought to work properly on e-readers now, and double spaced paragraphs are now slightly less than double spaced, which looks a lot nicer.
So yeah, let me know if you find any issues with it. I've squashed a few already but I don't doubt there *might* be more use cases I haven't accounted for.
Demos
Basic line breaks
This is line 1
This is line 2
Indented paragraphs
This is an indented line
Double spaced indented paragraphs
This is an indented paragraph with double spacing. This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.
This is an indented paragraph with double spacing. This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.This is an indented paragraph with double spacing.







101
Comments ( 103 )
Oh cool.
the reply... headers on a post aren't working right for me
y6y5rjyugj7uhnzuhynfgnyujgbmmmmmHTML5gfiut5gvi5x5djwihatektj5ihateyouknightyjftrvt
Not bad. Always disliked CSS when I was taking webdev, so more power to ya for understanding it
Das be good
God damn it, now I have to get used to hitting return once instead of twice for separating paragraphs and dialog...
Time to redownload a few files. Followed by a re-reading to ensure no errors in each one.
>>289815
No you don't? Nothing has really changed.
>>289821
Nevermind, I misunderstood.
But what if I prefered/liked the first format, where spaces were bigger?
Now make your gdoc importer understand "space after paragraph". :V
Is that what happened? I freaked out when I saw that the <hr>s didn't double-space anymore. Well, actually, they still do, but it's not as spaced as I liked it to be, since I usually use them to separate story segments. Without them, it seems a little too wall-of-texty. I preferred the old style, but I guess this works, too.
Oh, that's something I didn't consider. Multiple line breaks are going to collapse now...
Yay for improvements!
But... is it just me or is the reply system broken?
>>289829 holy shit, I was just about to report that!
Anyway, if this is spaced down, it's been fixed.
Also, what >>289831 said. They're fine inside the replies, but are null pointers for the area that shows who replied to a specific comment.
Proper paragraph tags! I've complained about this before.
ok but can you steel update storys or not
>>289790
You're missing out—CSS is good stuff.
(Browsers' interpretations of CSS on the other hand... Internet Explorer, I'm looking at you WITH HATE



)
"Basically this means that the indents ought to work properly on e-readers now"
In the beginning, there was shit. And then mobile devices were accounted for. EVERYONE GO HOME, THAT WAS THE BEST PART.
Still wish you'd differentiate line width and paragraph spacing, but I understand this is probably more "compatible" with different styles. Oh well—that's what user css is for, and proper paragraph tags make it so much easier (p:empty {display: none;} here I come)
Edit: Correction, no empty paragraph tags. All I actually have to do is lower the line height, nice.
>not using lorem ipsum
>shaggity daggity
Minor bug I found with the new code (at least I think this introduced it)
If a story page has a synopsis long enough to need the More clickie, then there will be a line break when it's expanded. Find/make one that cuts off mid-sentence to see it clearly.
(Seen on Chromium)
Glad to see the site improving so smoothly
>>289866
Poultron! Yay!
>>289829
Ya know, I find it a bit annoying when I find simple things that slip my mind, that aren't actually simple, and very, very crucial. There are times when you need the keys to your house, and you end up forgetting them when you walk to your door, not finding them. Then you have to crawl through a vent, dog door, or even under the house to get in.
Meh, anyway. I'm still waiting for more tags. Like instead of the usual romance, slice of life, etc., something new.
>>289874
Seconded.
Along with the fact that comment replies can't be seen. (Which has also been mentioned.)
Knightly, I think you might have broken coloured writing in stories. Or at the very least the BBcode of
[col or=green] [/col or]
Just noticed that it's not appearing correctly in the story I'm writing.
The only problem I'm getting is with replies.
When someone replies to yours (or anyone else's) comments, there is a little icon (
(I use FFox. This happens even with all my complements/scripts/anal dildos turned off)
I can't say I'm entirely in favor of the "reduced size double spaced paragraphs". I've just checked one of my chapters and it makes it look a little squeezed-together. Meh. More my taste than anything.
And the whole reply problem has actually been cropping up for the last day or two on me. Not sure exactly when it started. I use Opera.
Okay, something that has been causing my OCD to flare up, is that all of a sudden after this change, EVERY piece of text on my user page has become bolded, which is absolutely horrible on my eyes. Also, something else that's been bugging me is that colours don't carry over when you start a new paragraph, but bold does, which just makes it tedious when you like to write in a colour like I do. It would be easier to just stop, but I've been writing in this way for a long time and it's pretty much one of my quirks that I can't just drop like that. One final thing is that, as a personal preference, I liked the old paragraph layout, but It may just be because that was what I grew accustomed to of the months of reading on this site. In other words, I'll get used to the strange new format.
>>289829 Should probably state that indenting has gone somewhat whack now when I went to work on one of my stories. Some paragraphs indent more than others for some odd reason, even though they use the same tabs in the editor.
Is all old text automatically converted to the new system?
>>289832 plus you cant see the comment when you scroll over them, shame too, that was so convenient
Sweet. Now all we need is to be able to format/upload our stories in HTML and it's all good.
>>290097 Looks like it. My story looks different here now. Much less crazy with the over-spacing.
>>289852 Come on, nopony uses Internet Explorer! Well, other than as a way to download Chrome/Firefox/Opera, anyway.
That does look nicer. Nice job.
Fix this yet?
BBCode isn't working in the feature box, or at least it wasn't a couple days ago.
For some reason, replying to people is partially broken; the parent post's list of people who have replied to it doesn't include names and doesn't link properly. The actual posts that do the replying display and link normally.
>>289940 This is an example, both of what I am talking about, and of someone else with this problem.
Bug Report:
Multiple line breaks now collapse down to a single one. This kinda fucked up the section breaks in my latest fic. I tried [br ] (without the space, obviously) but that hasn't been enabled. Any way to force multiple line breaks now?
Regarding this: >>289831
I noticed that the reply links are like "https://www.fimfiction.net/blog/57394#comment/"
Isn't there supposed to be a number after that?
And for YouTube:
[youtube=http://www.youtube.com/watch?v=UmHdefsaL6I ]
[youtube= http://www.youtube.com/watch?v=UmHdefsaL6I]
[youtube=http://youtu.be/UmHdefsaL6I]
[youtube=http://www.youtube.com/watch?feature=player_embedded&v=UmHdefsaL6I]
Edit: I just saw this in a comment: [youtube=http://www.youtube.com/watch?feature=player_detailpage&v=cONmzaT4x10]
Remember that regex I mentioned in the IRC? All of these links work properly with it (although the first two are because of trim()). Actually, here's the code for it. All you have to do is press CTRL+C and CTRL+V:
For anyone curious but too lazy to look, here's knighty's current code:
>>290400 >reeking
Correction: wreaking
>>289829
Is there anything you are going to do to fix this? Because it is really reeking havoc with all of my posts and chapters. Please, please do something about this.
~Signed, InfiniteBrony
>>289866
Yeah, what Poultron said.
Lorem ipsum FTW.
>>290043
Because you left a bold tag open in your bio...
Seems all right. Scene breaks done up with an <hr /> look a bit narrow, though.
^ There should be more space between there, I reckon a full blank line's height above and below the line.
Yeah, things look a BIT tight but okay, but horizontal rules are real faint and real tight.
Actually even that is lookin' better than it did because it's even, now, and it used to be a little uneven with below/above-rule spacing, but it's real faint and so tightly spaced that the 'scene break' quality is getting lost. I'd like to see that tweaked a little more.
Especially since whitespace is being collapsed! That's painful. I don't do many textual stunts with my writing, but that's one that I use. Now, I can't end with a big dramatic line and have it look like 'the rest of the page is blank, then on to the next chapter'. I'm losing some cliffhanger flavor because of that- the end of the text is too close to the beginning of comments/navigation/etc. I've also been putting in leading space on top, but that seems to be much less affected, it turns out fine.
I'd like to see more space above and below horizontal rules, and I'd like to see more space right at the end (if you gotta collapse whitespace). And I have to wonder at the reaction of anypony who did a scene in impressionistic fashion where they had (for instance) a trance or time passing uneventfully or a coma or something, and put in lots of blank spaces to denote nothingness. That'd be an unintended consequence of fixing people's goofy linespacing decisions...
>>290655 Yes, but why does that effect every other part of my profile?
Which leads to another thing, the update also got rid of the closing bracket for that bold. I distinctly remember putting a closing to it at the very end when I first wrote it. I added it now once again since I know now that it disappeared.
While we're talking about BBCodes, can we have [sc]Small caps[/sc]? (See CSS font-variant)
Forced typewriter text with [tt] would be nice too.
>>289940 Well, they seem to be fixed now.
>>290838
Well no you obviously didn't. The bbcode parser runs off the data in the database, nothing has been changed.
>>290892 For the sake of not causing myself to pop a blood vessel from a pointless argument(on top of already having a bad day) I'm just going to drop that. But that still doesn't explain to me why something in my biography causes every other thing on my user page to change. I assume it has something to do with the new module layout that you implemented not too long ago?
What does BBC stand for?
YAY! That means I can actually format my stories novel style now!
>>290906
No. Not closing a bold tag is always going to mean anything enclosed in that (including page elements following it) is going to be bold, unless I pick up open tags and close them, which isn't entirely trivial but it is something I'm looking at
>>290847 Why not just let people use HTML, like on deviantART?
>>290847 Smallcaps can be done with [smcaps][/smcaps].
Nope, I don't like it. But doesn't matter if I do or not, this is still the best website for posting MLP fics ever and it's free. So I am not complaining. Thank you guys for all the effort you put into this website.
>>291205
Yep. Agreed. Thank you- we're only petulant because we're in love!
>>291134
Because I don't know how that works?
>>291178 New tag? NEW TAG!
>>291305 Google
>>291353
>>291413
>>291431 Greasemonkey
That line height is obnoxiously large.
Seriously.
Stylish FTW
>>290221 People use Opera? thats even worse
>>291353
>>291424 Stylish = longer battery life for only tweaking CSS.
>>291511 Opera has been better than Internet Explorer before I first used it back ahead of the time of MSIE 7... 'Tis really a silly subjective argument anyhow...
>>291178
Awesome
>>291431
The line height has always been 1.8em.
>>291636
>>291649
It COULD just be the new paragraph spacing. Whatever it is, it went from "ugly, but I can deal" to "I can't fucking read my own story, why do my eyes bleed?" So I finally got off my ass and reinstalled stylish to fix it.
Doublespacing inside a paragraph is for elementary school and draft-hardcopies.
>>291730
Digital reading is very different to reading on paper. 1.2 line spacing is absolutely ghastly for body text
>>291804
Knighty. It's a hell of a lot easier for me to read. Then again, I have a laptop, so maybe I'm sitting closer or something.
The current default is really bad. If someone opts to not indent, even double spaced paragraphs suffer from wall of text. Again, it may be due to the new paragraph spacing thing, but it's extremely hard to read body text now. removing the excessive whitespace between lines helps group the paragraphs. Maybe if someone has a stupidly long, 1000 word block of text, double spacing is easier, but for most of the work on this site, it's very very distracting to have essentially a blank line between each row. FWIW, Google uses 1.25 and CNN uses 1.5. Fox seems to use 22px (with 15pt font). I point these out because they are all pages that put quite a bit of time into being legible.
It's your site. Make the css w/e you want.
>>291833
First of all, we can throw google out because they're displaying a couple of compressed lines of text, not an entire body of work.
1.8 is probably a bit high, but it's not crazily higher than 1.5 which those 2 sites have, and as is fairly evident on the site in general, I like my padding. What's the point in stuffing things together in a manner we did in the 90s when we most people have considerably larger monitors now. Anyway I've bumped the double space margin to 1.5em from 1.0em. It was definitely too small.
>>291804
You're entitled to your opinion of course, though I can't say I agree. My personal stylish style (for long periods of reading on a 1920x1200 screen) is a 22px font, 1.25em line height, 0.5em between paragraphs in a 650px wide column with a #191919 background out to the edges of the screen and #EEEEEE text. Not saying it's the 'right way' or anything, but I see no reason the media should make a difference in line-height preference (double-spaced lines are not a replacement for a comfortable font size.)
>>290316>>290793
If you reeeeeally want blank space for artistic freedom, I imagine a non-breaking space on its own line would work. I can sort of see wanting it for the end of a chapter or between sections, which is why I'm posting this, but I really recommend any other uses be scrutinized carefully by authors. 98% of the time, fancy text tricks just detract from a work.
>>291838
In the 90's, I had a 18" 4::3 crt.
In 2012, I have a 15.4" 16::10 laptop panel.
>>291859
The only difference media makes is that double spacing between paragraphs costs more in print, so tabs are used.
>>291895
It was a special use. I have a first person pseudo stream of consciousness. Rather then hr or center some * * *, I just triple spaced. It was meant to indicate shift in thought w/o breaking text flow. It startled me, because someone told me I needed better separation in sections, so I went to look and saw all my breaks wiped out.
If you care, it's Dash's Birthday Present. Normally I just use hr.
This is a comment.
I just want it on record that there should be a mobile version of this site for Kindles, iPhones, ext. I'm having annoying as hell trouble typing my chapters with this son of a hitch.
This is an indented paragraph with double spacing.
This is an indented paragraph with double spacing.
I do not understanding.
>double spaced paragraphs are now slightly less than double spaced, which looks a lot nicer.
AGREED! That bugged me. I had to choose between no spaces between my paragraphs, or enormous vertical gaps.
I know of only 2 bugs in fimfiction indenting, and they're both still there, and I can see them both in the first paragraph of <url deleted because people kept visiting it, and I'm still revising>. I can't reproduce them in my comment here, sorry.
Bug #1: All the paragraphs have a single tab for the indent. The first line of the first paragraph, however, gets indented far more than the other lines. I think this is because it has mostly capital letters, and this is causing some problem with justification. When you mouse over it, it looks like there are spaces at the start of the line. But when I edit it, there are not.
Bug #2: If you put two spaces between sentences -- and I don't want to trigger an argument over whether that's the right thing to do, let's just note that many authors are deeply attached to their two spaces between sentences -- fimfiction will often mess up your document by breaking the line between the two spaces and starting the next line with a space.
One more problem: If I have lines that are center-justified in a google doc, and I import from google docs and then click the "indent paragraphs" button, all the center-justified lines get indented and are no longer center-justified. I have to go thru by hand and fix them all every time I update a chapter.
I steel can,t update my story plaese fix this ok
This is a reply. This is not a reply. This is in a state of superposition of being both a reply and not a reply. How can we collapse the wavefunction?
Do we lack a [spoiler][/spoiler] tag or am I not doing it right?
With the addition of smallcaps we can finally have MLP/Discworld crossovers
>>292996
Looking at the code, it appears as if a literal tab character has gotten through the parser. Have you tried deleting the tab and re-adding it?
>>295188
Yep, tried that, can't make it go away. It may also have to do with the fact that I had to enter the tab by hand on that line, whereas all the others got the tab from the "indent paragraphs" button. But that's never been a problem with other stories.
I just tried removing the uppercase, cutting the line short, and other things. For some reason the first line won't indent right on that chapter of that story no matter what I do.
>>295211
>>295188
This has been fixed. Thanks for the report.
>>292016 there is, you just replace the 'www.' with 'mobile.', there are some problems with screen turning on iOS (for me at least)
>>290349 Where the heck do you get all these codes?
>>297291 What do you mean?
For some reason, and I don't know if they're related, but the color tags no longer seem to work properly in the one fic I used them in...
Even if I got back and re-add them, it's not showing up in the text.
Not really an error, but it's really freaking annoying:
>>297825 All these links and blog posts about the site and stuff.
>>299317 Be more specific
>>299707 Like how you find all these banners and all this site data. Find bugs and correct them. How do you know all this?
>>300224 I started programming when I was ~12 years old. I know what I'm doing
>>300259 Wow! You are now my idol!

>>300267
Hey, I noticed that it seems that in the comments, it doesn't say what chapter the comment was posted for anymore. I used to see it on every story that I looked at, but now it seems that aside from a few times, the chapter number in comments doesn't seem to show up at all.
Is it some sort of mistake with the new coding?
Same problem as shadowed Rainbow, why cant I read chapter numbers on comments? I like to know which chapter they posted on
What's CSS? Counter Strike: Source?
>>306365
Cascading Style Sheets are a method of defining the presentational/visual/appearance aspect of a web page separate from the structural HTML. What this means, is that it allows webpage designers to define programmatic rules that govern how a webpage is displayed. Unlike your typical document in a word processor where you would apply style changes to individual paragraphs (which is a consistency nightmare, and impractical for dynamic content), CSS allows us to instead say "all paragraphs in this block should have their first line indented by 30 pixels, and have a 10 pixel margin above them" and have it apply to any content that matches the rule across the entire site (or rather, any page of the site that loads the stylesheet that says so).
TL;DR CSS is how you make webpages.
>>307816 I thought websites were made when two webpages really love each other.... and...
>>298955
I assume that's to keep the load on the database down. Having a heap of characters excluded like that probably wreaks havoc on the database load.
I cant see how many words ive read on my account. it doesent say my estimated words read on my user page. Help?
>>308721 But I honestly haven't been able to find one good story because of this.
Weird issue I found in all my stories; wherever I've opened and closed an italic tag in the middle of a line, like this, it starts a new line on the italicized word. Strange.