00:02
<Hixie>
yeah doing stream-based programming from JS is just exposing way too much complexity to most authors
00:02
<franksalim>
annevk, ok. fwiw, JavaScript events and TCP work fine together
00:02
<Hixie>
almost all protocols end up being framed anyway
00:03
<franksalim>
Hixie, it is true that most protocols end up being framed, but now each framed protocol needs to have a WebSocket binding defined
00:03
<Hixie>
annevk: btw i think the main source of argument on this topic is that many of the people on hybi for some reason want to use websockets for something other than browser-to-server communication
00:03
<Hixie>
franksalim: why?
00:04
<franksalim>
Hixie, how do you later XMPP over WebSocket?
00:05
<franksalim>
Hixie, align each XMPP stanza to a ws frame, or ignore ws frames and just send XMPP as strings?
00:05
<Hixie>
why would you layer XMPP over WebSocket?
00:05
<Hixie>
put your XMPP client on the server-side
00:06
<Hixie>
and then just speak an internal protocol to get the data the "last mile" from your server to the browser
00:06
<franksalim>
the internal protocol might as well be XMPP
00:06
<Hixie>
putting all the XMPP logic in the client seems like a lot of work for no reason
00:07
<franksalim>
it is the same amount of work as writing a new protocol that covers all of the XMPP semantics you want
00:08
<Hixie>
you hardly have to implement anything at all if you put the XMPP client on the WebSocket server
00:08
<franksalim>
and because XMPP is well known and widely interoperable, you have the option of connecting to other servers that are outside of your direct control
00:08
<Hixie>
wait you want your JS page to connect to arbitrary XMPP servers?!
00:08
<franksalim>
yes
00:08
<Hixie>
i suppose if you really wanted to you could do that
00:08
<Hixie>
dunno why you would though
00:08
<franksalim>
but for a moment let me pretend i am only concerned with first party servers
00:08
<franksalim>
and am willing to write my own protocol to go the last mile
00:09
<franksalim>
the complexity of the custom protocol is necessarily the same as xmpp
00:09
<Hixie>
no
00:09
<franksalim>
except, possibly, in the wire representation
00:10
<Hixie>
it's the same complexity as the protocol an XMPP client would have with the OS's graphics subsystem, maybe
00:10
<Hixie>
"show these strings as being online"
00:10
<Hixie>
"display this message"
00:10
<annevk>
Hixie, yeah, I get the idea from some emails they have started already
00:12
<franksalim>
Hixie, that is one approach
00:13
<Hixie>
do people speak XMPP over hanging GETs today?
00:13
<franksalim>
yes
00:13
<Hixie>
url?
00:13
<franksalim>
http://xmpp.org/extensions/xep-0124.html
00:13
<Hixie>
i'd love to see that
00:14
<Hixie>
what pages use that?
00:14
<franksalim>
chesspark, collecta
00:14
<franksalim>
i don't have a list. those are two i have used
00:14
<franksalim>
http://code.stanziq.com/strophe/
00:15
<franksalim>
also, Kaazing has an XMPP library that uses the WebSocket API. It implements the XMPP protocol over ws://
00:15
<Hixie>
man, and here i was thinking people would finally have an excuse to dump XMPP and use something saner
00:15
<Hixie>
oh well
00:15
<franksalim>
that might happen too :-)
00:16
<franksalim>
but nobody has rallied around a chat protocol with a JSON representation, for instance
00:16
<franksalim>
XMPP is the best we currently have
00:20
<Hixie>
anyway, to answer your earlier question, you would just send each stanza with its own WebSocket.send() call
00:20
<Hixie>
and would receive each stanza in a separate onmessage call
00:20
<franksalim>
that seems natural, to align each frame in the existing protocol to a websocket frame
00:20
<Hixie>
not sure how you'd deal with the wacky XML parsing rules
00:20
<franksalim>
but these bindings will need to be defined
00:21
<Hixie>
sure
00:21
<Hixie>
if people want to communicate across multiple servers
00:21
<Hixie>
just like HTTP and XMPP are defined above TCP
00:21
<Hixie>
you can define protocols on top of WebSocket
00:21
<Hixie>
i expect most to be proprietary though
00:22
<franksalim>
Hixie, I expect most (of the important ones) to be based on existing standard protocols
00:22
<Hixie>
i expect most of them not to be important :-)
00:23
<franksalim>
maybe that's too loaded a word
00:23
<franksalim>
interoperable clients and servers
00:24
<Hixie>
i think most uses of websocket will be for a dedicated server speaking to a dedicated page from that server
00:24
<franksalim>
Hixie, what do you think about TCP relays over WebSocket? A few of those have already popped up
00:25
<Hixie>
e.g. reporting analytics, state in multiplayer games, sending back and forth ad information
00:25
<Hixie>
s/from that server/from that server or using a script from that server/, i should say
00:25
<Hixie>
much like today XHR is used with XML and JSON files that are proprietary formats
00:26
<franksalim>
Hixie, since ws is cross-origin from day 1, it is too appealing for cross-site use to be relegated to that use case
00:26
<franksalim>
Hixie, so what about public AJAX services? "APIs"
00:27
<othermaciej>
annevk: we should probably make one for consistency with other HTML WG drafts, though there is probably not much need to file bugs
00:28
<annevk>
if you want it's not a problem
00:29
<othermaciej>
I'll ask MikeSmith to add one
00:30
<Hixie>
franksalim: yeah, those are almost all proprietary
01:57
<MikeSmith>
http://code.google.com/p/web-messaging-rpc/
02:19
<franksalim>
MikeSmith, I like the labels for that project: html5, messaging, rpc, worker, webworkers, xdm, websockets, server-sent-events
02:20
<MikeSmith>
yeah
08:23
<hsivonen>
my knee jerk reaction to making document.write more magic is negative, but I need to think about it
09:24
<Lachy>
can anyone in here make any sense out of these examples? http://www.w3.org/TR/2010/WD-html-bidi-20100304/#basedirection
09:25
<Lachy>
Especially the 2nd and 3rd examples, which seem to randomly have some words with their letters reversed, and seemingly random word order for no apparent reason
09:25
<Lachy>
well, the 3rd one has all the letters reveresed and word order reversed, expect for "html" which has its letters in the usual order.
09:26
<Lachy>
but I also don't get how the second one can claim to be displayed LTR, and not just use normal english word and letter ordering.
09:27
<annevk>
I think there is a convention that uppercase means characters with RTL hinting or some such
09:29
<annevk>
and if you just have hinting it stops at word boundaries or some such instead of the entire sentence
09:29
<Lachy>
it would make more sense if they just used examle letters from actual RTL languages, instead of trying to confuse people with latin letters
09:29
<annevk>
in the bidi world the convention is pretty well established I think and it is much easier to use characters that fall within the ASCII range
09:30
<annevk>
also, by using characters in the ASCII range you do not get the problem that it might be displayed incorrectly because the bidi implementation is buggy
09:30
<annevk>
which seems important
09:31
<Lachy>
they could just give the examples using real RTL letters, and then provide an image with the intended rendering
09:32
<annevk>
it explains this even: http://www.w3.org/TR/2010/WD-html-bidi-20100304/#notation
09:32
<annevk>
seems like a lot of additional work
10:38
<annevk>
all this crap about modular
10:38
<annevk>
all I see is more boilerplate
10:46
Philip`
doesn't see that, since he uses the WHATWG copy instead
10:47
<Dashiva>
I suppose it's an externality then :P
10:52
<annevk>
Philip`, fair point
11:46
<annevk>
fun, Ubuntu does not ship with either curl or cvs
11:46
<annevk>
guess that makes sense
11:49
<Dashiva>
What about svn?
11:54
<Philip`>
As far as I'm aware it doesn't even ship with GCC
11:55
<Philip`>
Software developers clearly aren't the primary audience of the default install
11:58
<annevk>
Dashiva, nope
11:59
<annevk>
still ships with apt-get though
11:59
<Dashiva>
Doesn't the update manager just frontend apt-get?
12:00
<annevk>
prolly
12:44
<mut>
arrg anyone around, could really do with a little help re .translate() on canvas
12:49
Philip`
guesses some people may be around
12:49
<mut>
heh
12:49
<mut>
hey Philip` ;)
12:50
<mut>
im having an issue, I have some things im drawing, and moving around the canavas with translate
12:50
<mut>
I was kind of stacking the translates if you know what i mean
12:51
<mut>
and I decided it would be easier if i make a variable, and change that, and do 1 translate at the end of the function, so when i restore it, i have a reference as to where the origin is for that drawing
12:51
<mut>
but it just breaks when i do that, and i cannot figure out why
12:51
<mut>
:P
12:52
<Philip`>
Uh, don't quite understand what you're doing
12:52
<mut>
http://stairbox.com/tom/test/ << thats what im working on
12:52
<mut>
and it works at the mo
12:53
<mut>
if you select left turn for ex
12:53
<mut>
butif you look at the code, i commented out what i was trying to do
12:53
<mut>
if that makes sense
12:53
<mut>
its in drawRun2 where the problem is
12:53
<mut>
but i used that method in drawRun1, and it seems to be fine
12:54
<mut>
as far as i can tell im using .translate correctly
12:57
<Philip`>
mut: Looks like the problem is you're mixing translate and rotate in there
12:58
<Philip`>
If you do e.g. "translate(10, 0); rotate(180 degrees); translate(10, 0)" then the second translation is relative to the rotated origin, so you end up back where you started
12:58
<mut>
oh
12:58
<Philip`>
and it's not equivalent to "rotate(180 degrees); translate(20, 0)" which is what you get if you just accumulate all the translations
12:58
<mut>
errm
12:58
<mut>
ok think im with you
12:59
<mut>
oh right, so if i shift the rotates beyond the last translate
12:59
<mut>
gotcha
12:59
<mut>
:)
13:00
<Philip`>
Hmm, maybe you're not actually doing translate-rotate-translate but you seem to be switching between translate-rotate (in the original code) and rotate-translate (in the run2Origin code) and they're not equivalent
13:00
<mut>
yea im with you
13:00
<Philip`>
Should be okay if you're consistent about the order of operations
13:00
<mut>
sorted
13:00
<mut>
:)
13:01
<mut>
yea sorted that, ill just expand and make sure it works across everything
13:02
<mut>
thanks a lot Philip`
13:02
<mut>
heh
13:02
<mut>
saved my bacon
13:05
<Philip`>
Mmm, bacon
13:10
<mut>
english bacon, or american bacon?
13:13
<Dashiva>
Carrying a coconut?
13:15
<mut>
eh
13:17
<Magical1>
is there a particular tag used to mark up an area of a document containing dynamic content (AJAX) in HTML5, before I apply WAI-ARIA to it?
13:35
<MikeSmith>
Magical1: <div class="dynamic-content">... ?
14:32
<lyhana8>
hi, how an old browser that doesn't know the <header> tag or other will behave with them ?
14:34
<Dashiva>
More or less like a <div>
14:36
<Philip`>
Less if the old browser is IE
14:38
<lyhana8>
but it can totally blow up a layout if the behaviour is unpredictable
14:40
<mut>
i dont know why they dont just use one of the open source rendering engines for ie
14:40
<mut>
started advertising ie8 on tv now :/
14:42
<lyhana8>
mut: which country ?
14:42
<mut>
uk
14:42
<mut>
banging on about its saftey and private browsing etc
14:42
<mut>
pfffft
14:44
<lyhana8>
did they explain tabs browsing ?? Cause a lot of people doesn't use them u_u
15:47
<mut>
errm
15:48
<mut>
yea tabbed browsing too i think
15:57
Dashiva
wonders how make firefox stop lying and actually open new windows as tabs
17:59
<LoneStar99>
Philip' you around?
18:00
<Philip`>
No
18:01
<LoneStar99>
k, figured out the following problem: http://urloid.com/error1
18:01
<LoneStar99>
it is a video
18:04
Philip`
will look when he is around
18:04
<LoneStar99>
the fix is a global, which would maintain the the last positions, for some reason after leaving the drawing scene it would start happening
18:04
<LoneStar99>
so a global X and Y fixed it
18:09
<LoneStar99>
thanks for your help
18:58
<mut>
any way to flip something in canvas
18:59
<mut>
with scale(-1, 1) or something
18:59
<mut>
cant find any way
19:03
<mut>
nm
19:03
<mut>
it was me being daft
19:03
<mut>
heh