Absolute element offsets--exercise in futility

L

Lawrence Krubner

David said:
David Mark wrote:
[...]
I know.  Some dumbshits would actually measure all the way to thetop
of the HTML and then try to work backwards to the positioned body.
Some might even recommend such an approach to newcomers (possibly with
a version of a debunked script that they themselves haven't even
used.)  Nothing surprises me anymore.
And, as you know, theirs looks suspiciously like my take, just years
too late.  If I am the one who designed the box and I tell you the box
isn't worth getting into, what does that mean to you?  Remember what I
said about browser sniffing, attributes vs. properties, etc.?  AmI
wrong on this one or shouldn't you be listening?
What I understand you are saying is that the jQuery offsets plugin was
inspired by code you wrote. Did I get that right?
What plugin?  I am talking about the offset function in the jQuery
script.
If I understand you correctly: Why do you think so?
It is obvious.
Apparently, according to you, it is not obvious that we are talking
about the same thing.

I only know of one thing and that is what I was talking about.  I
assumed you were talking about something else.


In fact, we are talking about the same thing. jquery offset was a plugin
before it became part of core. Calling jQuery.fn.offset a "plugin" was
not the best way to communicate what I was talking about.
Okay.
.......
Those long-winded offset.* properties are figured by styling and
injecting created DIV's and then measuring their computed styles
against expected outcomes.  My last (and most absurdly unneeded)
version of this function, which had evolved since before the turn of
the century, did the same thing in the same way with similarly named
variables.  Why they are exposing these properties to outside
intervention is anyone's guess though.

So mine was published in February of last year.  It was discussed here
and certainly compared to jQuery at some point.  In fact, this is one
of the functions that Matt Kruse kept demanding that I publish to
"prove" that I could write better code than Resig (as if that
mattered.)  Resig himself asked where my version of this was when I
first panned his script.  You think he suddenly lost interest two
months later?  Another demand was the also unneeded getAttribute
wrapper, which was apparently less than inspirational.


Why don't you just publish your scripts as a library then? If people
like your ideas, then your library will become popular. There is a lot
of competition out there, among the various libraries. The good rises
to the top. Surely offering something to the public would be more
useful than griping about other people's work? How much of your life
do you really want to spend posting to comp.lang.javascript, ranting
about the degree to which your ideas are better than everyone else's?
 
D

David Mark

Good designers build usable sites that degrade gracefully. Bad

Right. Not sites that break after a year or two, unless you exchange
a complicated, interdependent blob of Javascript, most of which was
probably unused.
designers build sites that are unusable for a significant portion of
the people who visit their sites.
Correct.

Good designers, such as Darren Hoyt
Who?

(darrenhoyt.com) insist on valid markup, clean CSS, minimal HTML and
Whatever.

Javascript that enhances a site, but which in no way limits the use of
the site. And Darren Hoyt uses jQuery in the themes that he builds.
And the designers who imitate him probably do as well.

And therein lies the rub. Valid markup, clean CSS, minimal HTML
(semantic?), etc. is how you build a proper document. You don't
slather jQuery all over it as it will break it for lots of people
immediately and slowly approach unusable for all.

Think of each version of jQuery as a time capsule for John Resig's
misconceptions. If you write stuff on top of it and then have to swap
the whole thing for another collection of misconceptions, chances are
that your stuff is going to break. Unit testing is an expensive
process, so what sort of strategy is that?

As for Mr. Hoyt. His site has a big old horizontal scroll bar at 800
x 600 and uses XHTML transitional markup (of course.) He's living in
the year 2000, just like Resig. Who told you he was a "good designer?"
 
D

David Mark

There is a strange kind of unreality haunting this newsgroup. The
attitude seems to be "I don't want people to use these libraries, so I
will close my eyes and cover my ears and say nyah nyah nyah nyah until
people stop using them."

Interesting take. Of course, it is the exact opposite of reality.
The reality is that lots of people are listening intently, including
the authors of the libraries, book publishers, Web startups, etc.
When I say I'm getting more requests for help from designers who are
using jQuery, I'm simply reporting what has actually happened.

We know the history. Thanks.
 
D

David Mark

David Mark wrote:
David Mark wrote:
[...]
I know.  Some dumbshits would actually measure all the way to the top
of the HTML and then try to work backwards to the positioned body..
Some might even recommend such an approach to newcomers (possiblywith
a version of a debunked script that they themselves haven't even
used.)  Nothing surprises me anymore.
And, as you know, theirs looks suspiciously like my take, just years
too late.  If I am the one who designed the box and I tell you the box
isn't worth getting into, what does that mean to you?  Rememberwhat I
said about browser sniffing, attributes vs. properties, etc.?  Am I
wrong on this one or shouldn't you be listening?
What I understand you are saying is that the jQuery offsets pluginwas
inspired by code you wrote. Did I get that right?
What plugin?  I am talking about the offset function in the jQuery
script.
If I understand you correctly: Why do you think so?
It is obvious.
Apparently, according to you, it is not obvious that we are talking
about the same thing.
I only know of one thing and that is what I was talking about.  I
assumed you were talking about something else.

......
Those long-winded offset.* properties are figured by styling and
injecting created DIV's and then measuring their computed styles
against expected outcomes.  My last (and most absurdly unneeded)
version of this function, which had evolved since before the turn of
the century, did the same thing in the same way with similarly named
variables.  Why they are exposing these properties to outside
intervention is anyone's guess though.
So mine was published in February of last year.  It was discussed here
and certainly compared to jQuery at some point.  In fact, this is one
of the functions that Matt Kruse kept demanding that I publish to
"prove" that I could write better code than Resig (as if that
mattered.)  Resig himself asked where my version of this was when I
first panned his script.  You think he suddenly lost interest two
months later?  Another demand was the also unneeded getAttribute
wrapper, which was apparently less than inspirational.

Why don't you just publish your scripts as a library then? If people

- Matt Kruse, October 2007

Or was that not a direct quote?
like your ideas, then your library will become popular. There is a lot

I don't want my library to become popular. You clearly haven't read
my thoughts on browser scripting in general.
of competition out there, among the various libraries. The good rises
to the top. Surely offering something to the public would be more
useful than griping about other people's work?

Kruse again? Or are you serious? Okay, the next steps are:

1. Wait until I publish what you are after (already happened)
2. Disappear for a year or so
3. Come back and start the whole damned conversation over again
How much of your life
do you really want to spend posting to comp.lang.javascript, ranting
about the degree to which your ideas are better than everyone else's?

You clearly haven't read too many of my posts (or anything else I have
published.) You should read first, write second.
 
O

Osmo Saarikumpu

Lawrence said:
There is a strange kind of unreality haunting this newsgroup.

We don't think so :)
When I say I'm getting more requests for help from designers who are
using jQuery, I'm simply reporting what has actually happened.

I guess you just made somebody's point there? If it was such a
cool-crosbrowser-library why would them deezigners need your help?

Best wishes,
Osmo
 
L

Lawrence Krubner

We don't think so :)


I guess you just made somebody's point there? If it was such a
cool-crosbrowser-library why would them deezigners need your help?


This is intellectually lazy on your part. You could have just as
easily asked "What makes these scripts so popular with designers?"

Or ever better: "Why do graphic designers use these pre-package
scripts? Why don't they write their own code from scratch?"
 
D

David Mark

This is intellectually lazy on your part. You could have just as
easily asked "What makes these scripts so popular with designers?"

Most Web designers are incompetent (including your jQuery-propagating
idol.) Anyone who has spent even a minute on the Web knows that.
Or ever better: "Why do graphic designers use these pre-package
scripts? Why don't they write their own code from scratch?"

AFAIK, nobody here has ever said anything about writing all of your
own code from scratch, yet it is invariably the first rhetorical
question out of the gate from every doubting neophyte that shows up.
Where do you get that?
 
O

Osmo Saarikumpu

Lawrence said:
This is intellectually lazy on your part.

Must be, 'cause I still can't see much light in your argument. I have no
interst in any JS library. Thus, I'm not driven by affections, either way.
You could have just as
easily asked "What makes these scripts so popular with designers?"

I fail to see how this question would change anything. Isn't it a
classic example of ad populum?
Or ever better: "Why do graphic designers use these pre-package
scripts? Why don't they write their own code from scratch?"

Or: why do flies like shit? Why don't they fancy veggies?

I guess that the intelectually lazy would answer: because they do not
know better && because they can't. I'm sorry, but at least in my lazy
eyes, you are majoring in making points hindering your position.

Best wishes,
Osmo
 
E

Eric Bednarz

Lawrence Krubner said:
This is intellectually lazy on your part. You could have just as
easily asked "What makes these scripts so popular with designers?"

Because they are graphic (I suppose you mean) designers, so they
a) don’t understand any of the problems and cannot judge its quality
b) the API will likely appeal to them because they are not programmers
Or ever better: "Why do graphic designers use these pre-package
scripts?

Are you seriously thinking that there is a relation between success and
quality (in any field)?
Why don't they write their own code from scratch?"

Eyeroll. Speaking about lazy, you haven’t been lurking here, right?

Something you missed that you could just as easily have asked is:
“What idiot would assign programming tasks to designers?â€

IMO it is fair to say that jQuery is to javascript what Frontpage
Express was to HTML. :)
 
L

Lawrence Krubner

Because they are graphic (I suppose you mean) designers, so they
a) don’t understand any of the problems and cannot judge its quality
b) the API will likely appeal to them because they are not programmers


Are you seriously thinking that there is a relation between success and
quality (in any field)?


Eyeroll. Speaking about lazy, you haven’t been lurking here, right?

Something you missed that you could just as easily have asked is:
“What idiot would assign programming tasks to designers?”

That's just it. These pre-packaged scripts allow designers to get a
wide variety of effects without having to learn how to program. The
market demand for these scripts is exactly that they enable designers
to do something new, without necessitating their spending time
learning a new skill. This is something you could easily figure out
for yourself. The people on this newsgroup seem intelligent, so if
they are unable to figure out something so obvious, then they are
being deliberately obtuse.
 
L

Lawrence Krubner

AFAIK, nobody here has ever said anything about writing all of your
own code from scratch, yet it is invariably the first rhetorical
question out of the gate from every doubting neophyte that shows up.
Where do you get that?


David, you've a remarkably poor memory. Just earlier today you wrote:

"Compared to any context-specific solution, jQuery is bloated and
slow."

Check it out, you can read your own words here:

http://groups.google.com/group/comp.lang.javascript/msg/dc9b78773cf5b7db
 
D

David Mark

That's just it. These pre-packaged scripts allow designers to get a
wide variety of effects without having to learn how to program. The
market demand for these scripts is exactly that they enable designers
to do something new, without necessitating their spending time
learning a new skill.  This is something you could easily figure out
for yourself. The people on this newsgroup seem intelligent, so if
they are unable to figure out something so obvious, then they are
being deliberately obtuse.

It isn't meant to be a brain-teaser. People do crazy things. Like
supposing that learning jQuery requires no time. As we've seen, the
maintenance alone will kill you. It's far more volatile than the
browsers it tries to abstract.
 
D

David Mark

E

Eric Bednarz

Lawrence Krubner said:
That's just it. These pre-packaged scripts allow designers to get a
wide variety of effects without having to learn how to program.

Who are those “graphic designers†I keep hearing about, as if it were a
real profession that needs trained individuals? Pushing pixels across
the screen is a matter of having the right software installed and
pressing some buttons (I foresee great entertainment value here).
The
market demand for these scripts is exactly that they enable designers
to do something new,

Huh? How do you something new with pre-packaged effects? You will be
happy to learn that unlike David, the cheap cheesy message of
e.g. prototype/ligthbox usage offends me more than its code base.
without necessitating their spending time
learning a new skill.

This brings up a good point. I actually think there is a big market for
this stuff, the rent-a-ninja-online business for clients who want a
funky website without necessitating their spending money on people who
charge for skills. That makes sense to me.
 
G

Garrett Smith

Eric said:
Because they are graphic (I suppose you mean) designers, so they
a) don’t understand any of the problems and cannot judge its quality
b) the API will likely appeal to them because they are not programmers


Are you seriously thinking that there is a relation between success and
quality (in any field)?

What does "success" mean to you?

Garrett
 
G

Gregor Kofler

Am Sun, 12 Apr 2009 16:36:34 -0700 schrieb Lawrence Krubner:
These pre-packaged scripts allow designers to get a wide
variety of effects without having to learn how to program.

No, that's /the/ misconception.

According to your logic graphics designers are supposed to congratulate
me upon my decision to use one of those fancy predefined webpage
templates, because it enables me to do "professional layouts" without
having to learn the basics of design. (Who cares if colors of fonts don't
match the chosen template, or the template doesn't match the CD of the
customer.)

Gregor
 
G

Gregor Kofler

Am Sun, 12 Apr 2009 14:06:40 -0700 schrieb Lawrence Krubner:


[snip]
Why don't you just publish your scripts as a library then?

Yawn... The usual implied "if you can't do better, stop critizing". Apart
from that you *can* download Mark's scripts. But then: Are you capable of
assessing the code quality?

Gregor
 
B

beegee

That's just it. These pre-packaged scripts allow designers to get a
wide variety of effects without having to learn how to program. The
market demand for these scripts is exactly that they enable designers
to do something new, without necessitating their spending time
learning a new skill.  This is something you could easily figure out
for yourself. The people on this newsgroup seem intelligent, so if
they are unable to figure out something so obvious, then they are
being deliberately obtuse.

I guess. I also guess that programmers, not designers will end up
doing the maintenance on most of these sites (that is, if the site
does anything besides look pretty). I think a lot of companies who
follow the pack fail to understand what the "big boys" are really
doing. They are not hiring designers to code the front end. They
hire designers to design the front end and programmers to code it. If
production of web sites was truly designer driven then what you say
might be true but all you need to do is look at the sites linked to by
Smashing magazine to see a certain low-level of functionality common
to most (though I personally really like looking at them).

Those of us who fear having to maintain sites coded with jQuery have
more to fear from back end javascript generators like Rails
(prototype) and Microsoft MVC (jQuery). Those systems spit out
unreadable javascript at an alarming rate.

Bob
 
D

David Mark

Who are those “graphic designers” I keep hearing about, as if it werea
real profession that needs trained individuals? Pushing pixels across
the screen is a matter of having the right software installed and
pressing some buttons (I foresee great entertainment value here).


Huh? How do you something new with pre-packaged effects? You will be
happy to learn that unlike David, the cheap cheesy message of
e.g. prototype/ligthbox usage offends me more than its code base.

I hate them just as much in the end-user role. You ought to see this
YUI-based monstrosity I was just dealing with. I love it when prats
decide they just have to have a "lightbox" and proceed to wreck an
otherwise useful document. The most outrageous examples (e.g.
Reddit's login) render critical UI elements off-screen and make it
impossible to scroll them into view. I don't bother complaining about
these things (who does?) as some fool on the other end will just
respond with drivel about "edge cases" and all of the great feedback
they get from their users. (!)

When you write this stuff, it makes it all the more aggravating when
some neophyte who wants to add jQuery or YUI or whatever to their
profile causes you to lose the form you just filled out, breaks your
browser, opens 30 HTTP connections on every navigation, etc. I have
really come to hate the Web lately.

My technical criticism is not just about code quality either. The
whole idea (a large, generalized solution for all browser scripting
occasions) was a foolish one. This is perhaps one of the worst trends
in software history and it couldn't come at a worse time for the Web
(browsers were finally starting to settle down and act alike.) For
most of the last decade, IE has been a constant, yet people are
rushing to adopt a script that is still mystified by things like
quirks mode. Ironically, it is often served with transitional XHTML,
which is completely incompatible with the script (not to mention IE.)

If there are two things you don't bet on at this point, they are John
Resig and HTML error correction.

[snip]
 
D

David Mark

Because they are graphic (I suppose you mean) designers, so they
a) don’t understand any of the problems and cannot judge its quality
b) the API will likely appeal to them because they are not programmers


Are you seriously thinking that there is a relation between success and
quality (in any field)?


Eyeroll. Speaking about lazy, you haven’t been lurking here, right?

My favorite is "Why don't you write all of your sites in
assembler?!!!" This is usually parroted by people who have no idea
what assembly language is (they just thought it sounded like a geek-
chic thing to say.)
Something you missed that you could just as easily have asked is:
“What idiot would assign programming tasks to designers?”

Lots of them, but fewer now than three months back.
IMO it is fair to say that jQuery is to javascript what Frontpage
Express was to HTML. :)

I always hear that jQuery is to Javascript as C is to assembler.
Kernighan, Ritchie and... Resig? Doesn't quite fit does it?

http://groups.google.com/group/jquery-en/browse_thread/thread/ee5b53d4982aefb5

How can it take so much work to be so utterly incompetent? These
people are too busy writing to stop and read anything.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,102
Messages
2,570,646
Members
47,254
Latest member
GayMilline

Latest Threads

Top