worldwide.kde.org going dynamic
Thomas already wrote about his nice Java applet which is is now part of the offerings on worldwide.kde.org.
- Zoom with Shift+Mouse
- Drag with your mouse
- Several higher resolutions for the background when zooming in.
- name placement, so nobody is missing
- Enlarge or Shrink the size of the widget itself (you need Konqeror for this, since Firefox is not able to do it
- switch between names and nicks
Check it out and let me know what you think about it.
I want to implement something like Google Suggest for docs.kde.org so I decided to get my feet wet with some JavaScript exercise. The Google Maps APIs seemed like a nice thing to level up my skills. Together with the documentation this was almost too easy. Took me about 2 hours without any real JavaScript knowledge to get a Google Map with all kde contributors up. Including using a XML file for names which has potential for showing almost everthing else.
This will not go to worldwide for the next time. Why?
- You need Konqueror from trunk to make it work.
- Since Google still ignores that Konqueror from trunk can render the Google Maps, you have to use a Safari user-agent to use the map.
- Both, Firefox and Konqi produce several “script needs too many ressources and will slow down your browser” windows. Seems more than 360 contributors are too much for the Google Maps
- Markers overlap, so contributors are hidden below others. No way around that except calculating a placement algorithm myself which means people end up in odd places. The script is bringing Firefox and Konqi almost to their knees already.
- No maps outside USA, UK and Japan. (thats why it defaults to “Satellite” for now)
I am using a XML file for the data, so perheaps I can somehow limit the count of markers which have to be submitted and need to be processed. Only one of many things needed to make this useful.
There is one nice thing missing in Thomas Java applet
- gorgeous pop-up windows showing the name and perheaps an image.
and Thomas is working on that. So after I work out how to get pretty buttons instead of the ugly Java standard ones on the applet it is much better up to the job than Google Maps.
Please leave a comment what you think about both of them.
16 July 2005 at 11:20
Your link to ‘Google map with all kde contributors’ goes to the Google maps API page.
16 July 2005 at 20:15
Rik, thanks for noticing, fixed now. Cut&Paste :}
17 July 2005 at 13:41
For people who are too close together, rather than displacing markers, have you considered using a single marker for multiple people?
17 July 2005 at 14:52
Elliot: Yes. But “too close together” can mean very different things on different zoom levels. Calculating this is beyond my JavaScript knowledge ATM. I could iterate over all already existent markers and add to their HTML. Which is not this complicated, but will make calculations take even longer. Please correct me if not, but this sound like a x^x problem.
23 July 2005 at 13:21
“Both, Firefox and Konqi produce several “script needs too many ressources and will slow down your browser” windows. Seems more than 360 contributors are too much for the Google Maps”
If i’m not mistaken you can solve this by using setInterval to call a function that adds the contributer at an interval (say, every few milliseconds).
1 August 2005 at 9:08
Cerulan: Thanks for that hint. I used a different method in the end (addOverlays()) which adds all markers at once. You pointend me in the right direction though. More details in an upcoming blog.