October 04, 2010
On 04/10/10 03:59, Walter Bright wrote:
> Lionello Lunesu wrote:
>> The new page loads terribly slow because of some embedded resource
>> from twitter.com. Twitter is blocked in China, so when I open your
>> website nothing is shown until the connection to twitter times out.
>> Perhaps you can use XmlHttpRequest in javascript to load the twitter
>> stuff on the 'background'?
>
> The previous page had the same javascript in it. I don't know how this
> one could load slow and the previous one not.
>
> Can you post a diff for how to change the html to load in the background?

Rather than getting the JS to load it in the background, the lazy option is to move the two <script> tags to the bottom of the html before </body> rather than before </head>. Browsers will block rendering of the page if it encounters a script tag until the script has been loaded - by placing them at the end the page will be rendered, followed by loading the scripts.

Alternatively you could use the HTML5 attributes with the script tag to make the scripts load in the background regardless, I don't know what browser support is like for this though.

-- 
Robert
http://octarineparrot.com/
October 04, 2010
On 10/3/10 18:09 CDT, Walter Bright wrote:
> http://www.digitalmars.com
>
> Yes, I should add some color and style sheets, but at the moment I am
> just trying to get the layout right and make it much simpler to get to
> what I think are the most useful links.
>
> Comments welcome.

Hm, looks like only on my machines the page looks broken (see http://img96.imageshack.us/img96/4693/screenshot20101004at122.png). This occurs on FF/OSX and Chrome/Ubuntu. On my other two combos, the DMDScript column is not misaligned, but the whole thing is still too narrow and doesn't fill the width of the browser window.

Could someone post a screen capture so I can figure how the site is meant to look? Thanks.


Andrei
October 04, 2010
On Mon, 04 Oct 2010 21:23:29 +0400, Andrei Alexandrescu <SeeWebsiteForEmail@erdani.org> wrote:

> On 10/3/10 18:09 CDT, Walter Bright wrote:
>> http://www.digitalmars.com
>>
>> Yes, I should add some color and style sheets, but at the moment I am
>> just trying to get the layout right and make it much simpler to get to
>> what I think are the most useful links.
>>
>> Comments welcome.
>
> Hm, looks like only on my machines the page looks broken (see http://img96.imageshack.us/img96/4693/screenshot20101004at122.png). This occurs on FF/OSX and Chrome/Ubuntu. On my other two combos, the DMDScript column is not misaligned, but the whole thing is still too narrow and doesn't fill the width of the browser window.
>
> Could someone post a screen capture so I can figure how the site is meant to look? Thanks.
>
>
> Andrei

Opera, Windows 7: http://habreffect.ru/files/532/fd0f166e1/digitalmars.com.png

Looks almost the same in IE and Chrome ("D", "C/C++" and "DMDScript" captions are all rendered with Times New Roman or similar font in those browsers).
October 04, 2010
On 10/4/10 7:23 PM, Andrei Alexandrescu wrote:
> Hm, looks like only on my machines the page looks broken (see
> http://img96.imageshack.us/img96/4693/screenshot20101004at122.png). This
> occurs on FF/OSX and Chrome/Ubuntu. On my other two combos, the
> DMDScript column is not misaligned, but the whole thing is still too
> narrow and doesn't fill the width of the browser window.
>
> Could someone post a screen capture so I can figure how the site is
> meant to look? Thanks.
>
>
> Andrei

It looks like this here: http://img838.imageshack.us/img838/816/screenshot20101004at742.png

Have you modified the default font size setting of the browser? If the page uses mixed em/pixel units, layout bugs like this could occur, although there is quite a lot of other possible causes for that.

By the way, I don't quite see how the vegetation-at-the-beach picture would qualify as background for a programming language news feed (http://twitter.com/D_Programming) – oh, and that file is about as big byte-wise as the rest of the page…
October 04, 2010
klickverbot wrote:
> By the way, I don't quite see how the vegetation-at-the-beach picture would qualify as background for a programming language news feed (http://twitter.com/D_Programming) – oh, and that file is about as big byte-wise as the rest of the page…

It's a picture I took years ago. The advantage of it is I don't have to get a license for it!

For example, on the http://twitter.com/digitalmars one I had to get a license from JPL to use the photo. Not that it was a big deal, it's just that it took time, I have to keep the license paperwork on file, etc.
October 04, 2010
Robert Clipsham wrote:
> On 04/10/10 03:59, Walter Bright wrote:
>> Lionello Lunesu wrote:
>>> The new page loads terribly slow because of some embedded resource
>>> from twitter.com. Twitter is blocked in China, so when I open your
>>> website nothing is shown until the connection to twitter times out.
>>> Perhaps you can use XmlHttpRequest in javascript to load the twitter
>>> stuff on the 'background'?
>>
>> The previous page had the same javascript in it. I don't know how this
>> one could load slow and the previous one not.
>>
>> Can you post a diff for how to change the html to load in the background?
> 
> Rather than getting the JS to load it in the background, the lazy option is to move the two <script> tags to the bottom of the html before </body> rather than before </head>. Browsers will block rendering of the page if it encounters a script tag until the script has been loaded - by placing them at the end the page will be rendered, followed by loading the scripts.

Done. Good idea!


> Alternatively you could use the HTML5 attributes with the script tag to make the scripts load in the background regardless, I don't know what browser support is like for this though.

October 04, 2010
Stewart Gordon wrote:
> The layout breaks in anything but the default text zoom.  Need to get rid of the mixed px/em sizes.  Instead, specify all the widths in %, and use another div within the div for padding.

Good idea.
October 04, 2010
Stewart Gordon wrote:
> The layout breaks in anything but the default text zoom.

The annoying thing about this is everyone says "don't use tables for layout, use CSS." Except that using CSS for layout DOESN'T WORK RELIABLY. With tables, I can get 3 columns that are actually 3 columns, not 3 columns that are a side effect of bugs in CSS.
October 04, 2010
"Walter Bright" <newshound2@digitalmars.com> wrote in message news:i8b2fn$4t9$2@digitalmars.com...
> http://www.digitalmars.com
>
> Yes, I should add some color and style sheets, but at the moment I am just trying to get the layout right and make it much simpler to get to what I think are the most useful links.
>
> Comments welcome.

Maybe get rid of the "Code of the Nerds" quote - it doesn't look very professional and doesn't seem to fit in with the rest of the page which looks good.

-=mike=-


October 04, 2010
On 10/4/10 12:42 CDT, Denis Koroskin wrote:
> On Mon, 04 Oct 2010 21:23:29 +0400, Andrei Alexandrescu
> <SeeWebsiteForEmail@erdani.org> wrote:
>
>> On 10/3/10 18:09 CDT, Walter Bright wrote:
>>> http://www.digitalmars.com
>>>
>>> Yes, I should add some color and style sheets, but at the moment I am
>>> just trying to get the layout right and make it much simpler to get to
>>> what I think are the most useful links.
>>>
>>> Comments welcome.
>>
>> Hm, looks like only on my machines the page looks broken (see
>> http://img96.imageshack.us/img96/4693/screenshot20101004at122.png).
>> This occurs on FF/OSX and Chrome/Ubuntu. On my other two combos, the
>> DMDScript column is not misaligned, but the whole thing is still too
>> narrow and doesn't fill the width of the browser window.
>>
>> Could someone post a screen capture so I can figure how the site is
>> meant to look? Thanks.
>>
>>
>> Andrei
>
> Opera, Windows 7:
> http://habreffect.ru/files/532/fd0f166e1/digitalmars.com.png
>
> Looks almost the same in IE and Chrome ("D", "C/C++" and "DMDScript"
> captions are all rendered with Times New Roman or similar font in those
> browsers).

Thanks. I update my opinion to "definitely crappy even in its intended look".

The three-column layout ignores the width of the browser and is unnecessarily cramped. What is this, a newspaper column featuring an obscure announcement?

The short width of the columns and the lack of hyphenation makes the text hopelessly ragged.

The icons are disproportionately large compared to the text.

The top three links are identical in the three columns, but there is no horizontal structure to acknowledge that symmetry. In fact the links inside columns form a menu of sorts, but are not visually laid out as menus.

The "site search" box is... out there.

"Code of the Nerds" is old. Drop.

I find it surprising that anyone on this forum finds this format even remotely passable, never mind better than the old one (which didn't set the bar all that high).


Andrei