A moment of reflection

By crisp on Thursday 4 November 2010 23:26 - Comments (25)
Category: HTML5, Views: 9.059

My editor just crashed with some unsaved data, 15 minutes of coding gone. Now it's time to stop cursing, take a deep breath and use a moment to reflect.

Your browser does not support canvas, so probably it is outdated and you could better use this time to install a better one!


Now, that helped :)

Oh, by the way: this is a throbber made using <canvas>. You may use it if you like it. Just use 'view source' for the code :)

Volgende: Lazy-loading print stylesheets 11-'10 Lazy-loading print stylesheets
Volgende: Internet Explorer 9 is the best HTML5 browser! 11-'10 Internet Explorer 9 is the best HTML5 browser!

Comments


By Tweakers user Joshua, Thursday 4 November 2010 23:33

Nice work! If we had a like button I would have pressed it. :P

By Tweakers user harrald, Thursday 4 November 2010 23:36

Your browser does not support canvas, so probably it is outdated and you could better use this time to install a better one!
thats a nice way to put it :+

darn editors always crashing on the wrong time!

By Tweakers user YopY, Thursday 4 November 2010 23:38

Only 15 minutes? Pah. Try spending hundreds of hours on a project, only to find out the original contractor ends up cancelling the project for reasons unknown, most likely related to them not wanting to invest the day or so of work still required :+.

Yes, that's much, much worse than your computer crashing.

Also, autosaves and ctrl+s spasms.

By Tweakers user Sibert, Thursday 4 November 2010 23:48

Start coding in Word 2010.
It has a recoverfunction :+

By Tweakers user Sebazzz, Thursday 4 November 2010 23:56

The second time you start coding, the result is always better :) Why don't you have a editor with autosave support btw?

By Tweakers user crisp, Thursday 4 November 2010 23:59

Sebazzz wrote on Thursday 04 November 2010 @ 23:56:
The second time you start coding, the result is always better :) Why don't you have a editor with autosave support btw?
I do, well sort-off, but somehow the recovery file was non-existent (notepad++ by the way)

[Comment edited on Friday 5 November 2010 00:02]


By Tweakers user AyeAyeCaptain!, Friday 5 November 2010 00:10

Sibert wrote on Thursday 04 November 2010 @ 23:48:
Start coding in Word 2010.
It has a recoverfunction :+
It hasa spellingschecker but does it also include a option for syntax coloring?

would be nice. :+

By Tweakers user NMe, Friday 5 November 2010 00:25

I still think a throbber with a self-animated set of PNG sprites would look better. :P

* NMe runs.

By Tweakers user crisp, Friday 5 November 2010 00:27

NMe wrote on Friday 05 November 2010 @ 00:25:
I still think a throbber with a self-animated set of PNG sprites would look better. :P

* NMe runs.
That's no fun; I did that already 7 years ago ;)

Besides: this is probably smaller in file size :P

[Comment edited on Friday 5 November 2010 00:28]


By Tweakers user CodeCaster, Friday 5 November 2010 00:41

I can't see the actual source now, but it seems to works on Android 2.2 :)

By Tweakers user RobIII, Friday 5 November 2010 00:52

It's "hard-edge" and "soft-edge" are the wrong way aroud :P Usually the darkest color leads and the fading colors follow. Which doesn't mean it has to be so, it just makes more sense to me that way. Now it seems to be running backwards :P

[Comment edited on Friday 5 November 2010 00:52]


By Tweakers user crisp, Friday 5 November 2010 01:33

RobIII wrote on Friday 05 November 2010 @ 00:52:
It's "hard-edge" and "soft-edge" are the wrong way aroud :P Usually the darkest color leads and the fading colors follow. Which doesn't mean it has to be so, it just makes more sense to me that way. Now it seems to be running backwards :P
Fixed that for you :*

By Tweakers user Sibert, Friday 5 November 2010 01:35

The previous one was better :|

By Tweakers user crisp, Friday 5 November 2010 01:40

Just switch

c = Math.min(255, Math.floor(150 + 20 * (12 - j)));

with

c = Math.min(255, Math.floor(150 + 20 * j));

;)

By Tweakers user ACM, Friday 5 November 2010 07:53

Sebazzz wrote on Thursday 04 November 2010 @ 23:56:
The second time you start coding, the result is always better :) Why don't you have a editor with autosave support btw?
We offered him a decent editor/IDE (first Eclipse+PDT, than later PhpStorm), but he is really fond of Notepad++ and doesn't believe in the usefullness of IDE's.

So this is the price he has to pay for that ;)

By Tweakers user ameesters, Friday 5 November 2010 09:17

using linux fixed all my problems i had with windows crashing... maybe a suggestion?
i found nano verry good at the job on the command line, gedit, bluefish or gphpedit. you could also use a fully charged eclipse if you want to. Hell it could even help you charge your OV chip ;)

what do you say, are you with me?! open-source FTW!!!

By Tweakers user i-chat, Friday 5 November 2010 09:19

YopY wrote on Thursday 04 November 2010 @ 23:38:
Only 15 minutes? Pah. Try spending hundreds of hours on a project, only to find out the original contractor ends up cancelling the project for reasons unknown, most likely related to them not wanting to invest the day or so of work still required :+.

Yes, that's much, much worse than your computer crashing.

Also, autosaves and ctrl+s spasms.
lol - so why do you care.... .you got paid didn't you, if not than your 'one stupid SoaB" lolz!
ACM wrote on Friday 05 November 2010 @ 07:53:

[Sebazzz wrote on Thursday 04 November 2010 @ 23:56:]
[...The second time you start coding, the result is always better :) Why don't you have a editor with autosave support btw? ...]


We offered him a decent editor/IDE (first Eclipse+PDT, than later PhpStorm), but he is really fond of Notepad++ and doesn't believe in the usefullness of IDE's.

So this is the price he has to pay for that ;)
- I do wonder though, i cant seam to find any decent 'real world' blog item about this subject and ofcource i really do wonder why someone would prefer not to use a fullblown IDE. 'i mean most blogs about 'why you should use an IDE', are full of crap so crisp if you would be so kind as to try working with an IDE for 1 (one) week and share with us why you like or dont like it that would sirriously make for interesting reading.

[Comment edited on Friday 5 November 2010 09:38]


By Tweakers user Jogai, Friday 5 November 2010 09:47

The top stroke is too long grey as if the animation stops there for a moment.

By Tweakers user EnzoMatrix, Friday 5 November 2010 10:35

Jogai wrote on Friday 05 November 2010 @ 09:47:
The top stroke is too long grey as if the animation stops there for a moment.
thats because it does. it goes around, then it goes around again, starting over.

By Tweakers user crisp, Friday 5 November 2010 10:57

Jogai wrote on Friday 05 November 2010 @ 09:47:
The top stroke is too long grey as if the animation stops there for a moment.
Indeed, I did not notice that untill now. I'll fix that when I feel like it, but I do take patches as well ;)

By Tweakers user MueR, Friday 5 November 2010 11:19

ACM wrote on Friday 05 November 2010 @ 07:53:
[...]

We offered him a decent editor/IDE (first Eclipse+PDT, than later PhpStorm), but he is really fond of Notepad++ and doesn't believe in the usefullness of IDE's.
In fairness, Notepad++ does have something that phpStorm lacks dearly: single file editing.

By Tweakers user ACM, Friday 5 November 2010 12:09

MueR wrote on Friday 05 November 2010 @ 11:19:
In fairness, Notepad++ does have something that phpStorm lacks dearly: single file editing.
True, I actually have four editors I use regularly. PhpStorm for most PHP-work, Eclipse for the Java-work, Notepad++ for single file-edits and GVIM for when I need to do some advanced text-transforms in a file (i.e. its integrated regexp-support is very powerful).

By Tweakers user ReneDx, Friday 5 November 2010 19:25

crisp wrote on Friday 05 November 2010 @ 10:57:
[...]

Indeed, I did not notice that untill now. I'll fix that when I feel like it, but I do take patches as well ;)
Fast debug:

replace
code:
1
if ( ++j > 12 )


with
code:
1
if ( ++j > 12 && i < 11 )



Edit:
It solves the first bug, but creates an 'heartbeat' effect. Sorry 8)7

[Comment edited on Friday 5 November 2010 19:29]


By Tweakers user crisp, Saturday 6 November 2010 21:51

ReneDx wrote on Friday 05 November 2010 @ 19:25:
[...]

Edit:
It solves the first bug, but creates an 'heartbeat' effect. Sorry 8)7
Never mind, thanks for trying :)

Meanwhile I fixed it myself :)

By DiSiLLUSiON, Tuesday 16 November 2010 03:36

We offered him a decent editor/IDE (first Eclipse+PDT, than later PhpStorm), but he is really fond of Notepad++ and doesn't believe in the usefullness of IDE's.
A decent editor doesn't take ages to load. Notepad++ starts up in a snap, always and with the previous workset. It never fails on me. It never lags. And it's pretty much completely configurable. I agree with crisp on this; I love the damn program to death.

On the autosave thing; you know Murphy's law? Exactly. Much better to turn autosave off in the first place and simply ctrl+s, ctrl+s and ctrl+s until it's so ingrained in the muscle-memory of your left hand that you don't even realize you're doing it twice every minute. :*)

Comments are closed