In drupal, theme system makes the page looks better. But I feel strange that why theme system controls the layout of the page. I mean that some element on the page are fixed in theme, but not module or block, for example, the top block of the page. I think this is a bad idea that theme system can control the layout, except looks style. For the example above, I think there should be a block called "top" or "banner" to decide the layout of the top block ( logo, link, or so ).

Comments

robertDouglass’s picture

I think that all presentation decisions should be passed on to the themes. I especially like the way that one can write templates for node and block in phptemplate.

- Robert Douglass

-----
visit me at www.robshouse.net

Magicloud’s picture

I think...the layout should be controled by the thing that product this block, but the look-style( like color, font size, or so ) should be controled by the theme. So we can get a uniform-look, and a flexable layout.
As how drupal does now, the top of the page is fixed, unless I change the theme, which also means that in another theme, maybe I can not get the same layout as it is now.
And, as how drupal does now, it is hard for a normal user to design the total layout of the page as he likes.
And more, as the theme system is now, I should crack the theme files to modify the layout of the page to use some modules, a few modules of these can make the modify-work a mad. Just because the theme controls the layout.

robertDouglass’s picture

The difference that you are making between layout and style is one that is completely addressed by the .css stylesheet(s) that apply to your theme. You are right that Drupal does nothing to assist people in designing stylesheets - that is not its purpose as far as I can tell. A module that allows users to change style attributes would be nice, and may exist already (can someone comment on this?), but at the end of the day, moving more html generation into the code that produces blocks, nodes, the header and the footer is not what we want.

Did you know that no matter what theme you are using, you can completely change the layout and the colors and the text and every other visual element of your site just by modifying the .css files? If this is new to you, please look at http://www.csszengarden.com/ for inspiration.

- Robert Douglass

-----
visit me at www.robshouse.net

Magicloud’s picture

Maybe my description is not clearly, my english is poor....
As you said, i can use css to control the style, that is right. While I do not care if drupal can help me to design or not.

But as you said, I "can completely change the layout and the colors and the text and every other visual element of your site just by modifying the .css files", so How to modify the top area (logo, links, search) of the page's layout by change .css? For example, I want more links, and no search, need not I change the template file?

And as I metioned, this arch is helpless to the things like:
User theme. User can do nothing if he want a self photo instead of the drupal logo. No self theme here.
Some modules. These module need to modify some "blocks" to insert some text area or so. But because many layouts are in template file, so I need to modify theme again and again, which makes the theme a mad. And if I change another theme, all modifies lost....

I have some exprience on web application design, and in my opinion, I think the arch of the system should be:
a backend, which deals with the data.
a module system, which orgnizes the data as it wants and app logic.
a block system, which only controls its layout.
a theme system, which makes the web a uniform looks.

robertDouglass’s picture

I like the way you separated the tasks in your description, and I understand more what you want to do.

You can add links and turn off the search using the administrator interface for xtemplate and phptemplate at least (don't know about the others).

- Robert Douglass

-----
visit me at www.robshouse.net

Magicloud’s picture

So, wish the core develope team will think of my idea.