Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Nao
3391
Kill! Kill! Kill!

Oh, they're not mentioning whether perv video games are good for the libido... :lol:
3392
The Pub / Re: Language editing inside Wedge
« on March 19th, 2013, 07:28 PM »
Quote from Arantor on March 17th, 2013, 05:40 PM
WHY are they converted to brs at runtime? They're only converted as far as I can see through the textarea component. Other than that, they should NOT be there.
The agreement..?
Register.php
loadLanguage('Agreement');
$agreement = parse_bbc($txt['agreement']);
Or something to that effect...
So, it's converting newlines to br's. Thus, you have to choose between a HTML string (English version), or a BBC one (French version)... Which one do we get..? I vote for BBC.
Quote
That is because you need to set $settings['language'] to french, or otherwise set the default language in the admin panel.
Hadn't done it, indeed. ;)
3393
The Pub / Re: Spell checker
« on March 19th, 2013, 06:33 PM »
Quote from Arantor on March 19th, 2013, 05:28 PM
Your English is better than my French
Yeah, but did you learn French at school? For 8 years..? I'd say this doesn't compare :lol:
Quote from Arantor on March 19th, 2013, 05:28 PM
- and your English is better than the English of most people in this country. I really wouldn't worry about it :)
I never worry about it...[1] Only in professional situations!

Phew, I just spent an hour writing my latest changelog... 95% of which was on the lyrics thing, ah ah... Well, problem is I discovered Sugizo had made a new album so I had to get it, and it crashed my browser so it lost all my text, and I forgot about drafts (I just checked, I had one!), so I rewrote everything, plus the browser insisted on being updated when it restarted, so I did that, and now the tab bar is just narrow enough that I get the sidebar in wedge.org, how fun... :^^;:

Where was I, already..?
 1. I only worry about my accent. I can make a video of myself if you'd like -- just to see how horrible it is!! :lol:
3394
Features / Re: New revs
« on March 19th, 2013, 06:29 PM »
rev 2010 - I kept dreaming of a world I thought I'd never see. And then, one day... I got in.[1] / Jeo haneur wi nunmullo geurin baramui soksagim gubigubi ttaraga geu soge jamdeunda...[2] / (...)[3] / À la belle étoile... Quelques étoiles fuyantes, et toi la bonne étoile.[4]
(7 files, 6kb)

! Finally fixing that undefined index error in QuickMod... Never really knew why it occurred, but there are more important things in life. (QuickMod.php)

! Ah, the joys of automatic replacements eh, Pete...? ;) Fixed $settings['language'] (the entire variable) being globaled several times... (Subs-Post.php)

! Fixed indenazi function for lines starting with text. My original intent was to prevent <pre> code from being indented, but then I realized that Wedge adds spans to them instead of just showing tab characters, so... (Subs-Template.php)

! Fixed reqWin('url string') not working since the jQuery update. I wouldn't recommend doing that, though... Also removed a couple of workarounds that were no longer necessary. Saved 7 bytes all in all. (script.js)

* Translation. Partial for notifications, I stopped in the middle to fix the English version and, one thing led to another... I'll finish it next time. (ManageSettings.french.php, Notifications.language.php)

* Commenazi. (ManageLanguages.php)
 1. Daft Punk, 'Tron Legacy'.
 2. Jang NaRa, a beautiful song from 'Dong Yi', a Korean period drama. Same composer wrote 'Dae Jang Geum' back in 2003, my first (and favorite) Korean show. I wanted to quote him back then, but Pete took the spot :lol:
 3. Insert Sugizo song quote here. Damn, can't find lyrics... He released some damn good singles that year. He's the guitarist for Luna Sea and X Japan, my favorite J-Rock bands, their best composer as well, a very gifted arranger, he works with Origa (who sang the Russian songs in Princess Arete in 2000), and is also a member of Juno Reactor... What's not to like?
 4. La belle étoile, in 'Les saisons de passage' (Mathieu Chédid). Best live/rock album of the year for me... You should listen to some French music guys -- it rocques!! :D
3395
The Pub / Re: Spell checker
« on March 19th, 2013, 05:25 PM »
Well, you have to remember I learned most of my English on the Interwebs, and there isn't a UK/US flag next to English text, so I caught some typically US expressions/spellings, and some typically UK ones. I don't mind if I show my weaknesses on this board or whatever -- I just need to ensure I don't mix them up in Wedge itself... Which would look unprofessional ;)
3396
The Pub / Re: Spell checker
« on March 19th, 2013, 04:29 PM »
Today, I learned that while I insisted to write 'feasable', the actual English word for that was 'feasible'.
Thank you, embedded spellchecker :D
3397
Features / Re: New revs - Public comments
« on March 19th, 2013, 04:27 PM »
Oh, now I know... I think EmailTemplates was ISO earlier, because it didn't have any accents in it. I added accents when I translated your 'desc' strings... :^^;:

Also...

- Although I'm not enchanted with the idea (when it comes to updating website files via FTP, it's two or three extra folders to check out), I guess it'd make sense to put all languages into their own folders, for simplicity. If you don't want that, then good; if you do, then I won't oppose it.
Quote from Arantor on February 3rd, 2013, 11:00 PM
I did wonder about that, but I thought since it was configurable, there was really no reason for me to make it unconfigurable as such.
Well, there are many settings we never hesitated to remove to make room for others or just breathing space... ^^
Quote from Arantor on February 3rd, 2013, 11:00 PM
But yeah, realistically I don't see anyone looking to remove it any time soon.
I'd rather the draft autosave be attached to the editor to be honest. In practical respects it makes little difference; there aren't many cases where guests will be able to post (so we won't be loading the editor anyway)
Speaking of which. Isn't it feasible (ah, finally got the spelling right!) to just keep the editor out of topic pages, and when clicking 'Full editor', load it through Ajax instead...? I'm not afraid of these Ajax calls anymore. :P And it would save quite many bytes to topic page.
Quote from Arantor on February 3rd, 2013, 11:00 PM
Quote
- txt.done in spellcheck.js -- however, I'd advise against adding it for one reason: if you're not using the default language, you'll get another instance of your language name in the spellcheck JS URL,
Well, this strikes me as a reason not to do it there - if we keep the spell check, and I'm not entirely sold on that yet. For my money we need to support enchant if we're keeping it going forward (and I can't seem to get enchant to play nicely), and browsers often do a better job anyway.
Speaking of spellcheck, I'd like to point out, the buttons/spell.png file is still in SVN... Shouldn't we remove it? It's not used anywhere right now...
Quote from Arantor on February 3rd, 2013, 11:00 PM
I have to be honest I always found the entire toggle code something of a strange one, it always seemed more complicated than it had to be.
In SMF, definitely. Nearly 4900 bytes of crap! Wedge reduces the (uncompressed) code to about 2300. It's still useless, but at least it's the size it should be!

Regarding JS, I have more issues on my side with the reqWin rewrite. Well, just one really. Before committing it, I'd like to ask: is it really worth having a flexible first parameter..? 99% of all calls are "reqWin(this)". This then takes the href param in the owner anchor. Then there are, IIRC, four other calls:
- say/ask both pass an empty string as the first parameter, because they don't want to provide a title anyway; doing $('') shouldn't cause any trouble, so no need for the extra test;
- there's an occurrence in Active Topics (from John) and one in one of your plugins (I think it's WedgeDesk, I'm not sure though), where it sends reqWin('url string'). I've fixed Active Topics to do it the 'proper' way, i.e. put the URL into the href (so that it actually gets prettified and optimized by Wedge... I think??!!), and do reqWin(this) instead.
- I didn't fix yours, because it's more complicated... It's in your attachment code, have a look, in WedgeDesk-Display.php. Do you think it's fixable, if anything..?

The only thing I can say is, while it's a good thing to say "reqWin can open a custom URL if you provide it in the first parameter", I don't know if it's worth the extra 3 bytes of code to account for this when it's actually used nowhere at all in Wedge...?

(And please, please please say "yes it's worth it, now bugger off with your three petty bytes".. I'll feel better about it!)
Quote from Arantor on February 3rd, 2013, 11:00 PM
Quote
* Naoism: comment typos. Also, Pete, you must have a 4K screen if you're able to read that MessageIndex comment without scrolling... ;) (MessageIndex.php, Pin.php)
Or not. MBP 17" = 1920x1200. Just see the attached.
Now that's pretty crazy... ;)
I still prefer for // comments at the end of a line of code to be either very short (a few words at most), or moved to their own line (or move, if needed). That's pretty much a 'SMF/Wedge coding guideline' to me... Do you think you could do that in the future..?
3398
Features / Re: New revs - Public comments
« on March 19th, 2013, 04:03 PM »
Oh, I hope you don't mind, but I hijacked your 'pop-culture references' part ;)
I don't mind that you get to commit a few things and thus choose something for the corresponding year, but I felt that not having anything at all was a sad waste of mindfuck :P
Quote from Arantor on March 19th, 2013, 02:40 PM
Yeah, that's the plan. I'm working on the fallback right now. I'm not sure how Brazilian is going to work, whether I need to figure out some 'language invoking another language' but I can't see any way that can meaningfully work all that well.
Me neither... :-/
Quote from Arantor on March 19th, 2013, 02:40 PM
English UK falling back to English US works well enough, and I'm fine with English US being a master fallback,
Even though these damn Americans came second, we know!! :P
Quote from Arantor on March 19th, 2013, 02:40 PM
Also, EmailTemplates.french.php doesn't work properly; the accented characters are encoded in ANSI, not UTF-8. I've fixed it locally and will commit it with my next commit.
I'm surprised I didn't catch that... :-/
I may forget it for new files, because it's ISO by default IIRC, but it's an old file, I thought I'd converted them all...
Or maybe I left it aside because e-mails weren't sent (or aren't sent??) using UTF...?
3399
Features / Re: New revs - Public comments
« on March 19th, 2013, 02:33 PM »
Quote from Arantor on March 19th, 2013, 02:19 PM
r2008 - I suspect the main reason for legalise_bbc was Karl ;)

Also, given the changes to the languages to de-Britishise things, I'm tempted to get my own back(!) by adding English (UK) to the SVN. Thoughts? There's some practical advantages, it will helpfully mean I won't be tempted to keep Britishisms in the trunk, and more than that, it will give me proper testing for the whole language caching thing where it stores other languages in the cache too.
I'm all for having a UK language file in there, of course! British are cool. (Matt Smith voice.)
Hell, it's long overdue. And I knew you planned to have one anyway. And it'd be easy to maintain -- just keep the lines that change, once the English fallback is restored...
Or you could have a 'patch' system that tells Wedge to change this or that word on the fly. But I can hardly see that one as working for anything else than British English... Brazilian, maybe..? Don't remember... And local variations, of course. Well, maybe it's not that bad an idea.
Oh, I used that page to do the final conversions:
http://www.lukemastin.com/testing/spelling/cgi-bin/database.cgi?action=rules
I knew most of the rules, but not all. Also, not all US '-ise' words are listed, but I trusted my instincts whenever I wasn't sure. I also converted -ising and -ised.
3400
Plugins / [Plugin] Re: Notifications system (1.0)
« on March 19th, 2013, 09:58 AM »
- Hmm, are you sure you can do it? Doesn't that bother you?

- @if member is a trick I only recently added, you'd have surprised me if you'd implemented it that way, actually ;)

- I can do that, if you want... CSS/JS is my area of expertise these days, after all :P

Also... Where the heck is the admin page for setting up notifications...? I couldn't find it. The language files mention "Admin > Plugins > Notifications", so I'm trying to update them to the correct position...

Ah, and the notification popup is incorrectly positioned in my local install. I was wondering, could you test on your side with the latest revision? I'm wondering if it's a browser issue or a bug I introduced when optimizing your JS code... (I did some pretty big changes and didn't know *where* to test, so I wouldn't be surprised.)
Posted: March 19th, 2013, 09:39 AM
Quote from Nao on March 19th, 2013, 09:39 AM
- @if member is a trick I only recently added, you'd have surprised me if you'd implemented it that way, actually ;)
I only recently added it in JS, sorry, it's been in Wess for a longer time ;)

I mixed things up in my head. Which reminds me: notifications.js was a stand-alone file because it was a plugin to begin with... Now that it's a core feature, we should be integrating it into script.js, all right? And add the infamous @if member to it, of course ;)
3401
Archived fixes / Re: reqWin / weUrl / jQuery bug?
« on March 19th, 2013, 09:53 AM »
Okay... Fixed :eheh:

Wasn't due to the first line, but the second. (Chrome led me into thinking it was the first.)
i.e., $(from).text(). I optimized that line to that size specifically because jQuery was ignoring URLs fed to it, so $('http://...') would just be ignored. Now it seems (in 1.9+) to generate an error. More specifically, the ':' is the one that causes the crash.

So, I just added the same test before it, and it works. It adds an exact 3 bytes to the code.
Then I removed a hack that was just a few lines below, which I'd forgotten to do -- I'd added a 'note to self' to remove it once we'd go for jQuery 1.8. Saves 9 bytes. And finally, I removed another hack for something that caused problems last week, but seems to be working now, probably the result of another fix I added in the meantime... I don't know. I don't care.

All in all, the script.js bytesize is now 7 bytes shorter, and works better. Thanks, Pete! ;)
3402
Archived fixes / Re: reqWin / weUrl / jQuery bug?
« on March 19th, 2013, 09:23 AM »
So, I worked a bit on this this morning, and it's really odd... It fails at from && from.href, and it does too in jQuery 1.9, so it might be a Chrome bug, but right now I'm using Sleipnir, which is based on Chrome 22, and thus a rather old version, so I guess if it wasn't fixed in the meantime, it's... not a Chrome bug..??!
Very strange.

I don't want to have to do a fix that takes too many bytes. I have to get to the bottom of this... :-/
3403
Features / Re: New revs
« on March 19th, 2013, 09:19 AM »
Woohoo above ^

rev 2008 - Yeahhhh, shall I cut you down... Yes 'twould be a last physical communion, I'll be gentle! I'll be gentle! I'll be gentle! I'll be gentle![1] / Komonangayo Bandeko Makila Mabe Oyo...[2] / Sublime... Pour moi, c'était sublime.[3] / Tududum, tududum.[4]
(33 files, 7kb)

* I don't know why I was putting up with regex replacements in Wess's comma protection, when I could have just gone for a str_replace... (Class-CSS.php)

* Changed all files to americanize British endings (optimise, sanitise, colour, etc.) I'm not touching WedgeDesk though, as it's 100% Pete's thing, and maybe he wants to wave the British flag with pride on it. Or something ;) An important change is that I renamed wedit::legalise_bbc to legalize_bbc, and I couldn't be certain that the word 'legalise' isn't commonly used in the US. (30 files -- do they need listing..?)

! Missing $settings global in $language rewrite. (Are there other..? I only fixed the one I found in my error log.) (Subs.php)

* Commenazi. (index.php)
 1. Comus, 'Drip Drip', 1972. I missed that year but they performed it live in 2008 and it was recorded on an album so I'm using the opportunity, eh eh. As for the lyrics, they're a parody, don't be scared, I just happen to love the way the guy sings it! :lol: http://fox.noisen.com/4841/comus/
 2. These lyrics are totally my guess, I don't speak a word of Congolese and lyrics can't be found online... It's from Shadow by Papa Wemba, in Peter Gabriel's "Big Blue Ball", my favorite album of his since one of my two all-time favorite soundtracks, "The Last Temptation of Christ", in 1988. Which I, oddly, forgot to mention back in rev 1988. My other favorite soundtrack, even more oddly, is Shinku no Shônen Densetsu, a Saint Seiya movie, which was... my choice for rev 1988. That was a pretty good year for instrumental music...!
 3. Christophe[1], 'It must be a sign', in his beautiful "Aimer ce que nous sommes" album. I must also mention that it was his last album until yesterday, when he released a new one. I must get it!
 1. Whom you may know from a song in Kill Bill... I guess not! It was only an instrumental.
 4. Well, have nothing better to offer for The Dark Knight!
3404
Archived fixes / Re: reqWin / weUrl / jQuery bug?
« on March 18th, 2013, 10:37 PM »
Sorry -- won't be able to test until tomorrow morning, in the end. Too tired for tonight. :(
3405
Archived fixes / Re: reqWin / weUrl / jQuery bug?
« on March 18th, 2013, 07:57 PM »
Busy right now. Will look into it tonight.