Posted by yhager on March 14, 2008 at 10:13am
| Project: | Administration menu |
| Version: | 6.x-1.1 |
| Component: | User interface |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
The attached are the modifications needed for the CSS, and an image to support RTL languages.
In D6 this file will be used automatically, in D5 it requires a patch, or support from the theme.
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| yh.patch | 751 bytes | Ignored: Check issue status. | None | None |
| arrow-rtl.png | 273 bytes | Ignored: Check issue status. | None | None |
Comments
#1
This patch alters the default stylesheet. Isn't there a clean CSS way to conditionally support RTL in Drupal 5?
#2
Please note this patch creates a new file called admin_menu-rtl.css.
There is no standard way to support RTL languages in D5, so I chose the approach that is also supported for D6 - it includes the "-rtl.css" file right after the standard one, so the original CSS is untouched.
For more information on D6, see http://drupal.org/node/222782.
This patch can be used in the future D6 version of this module, or in D5 with a little bit of hackery. If you feel this is not good enough for committing, then leave this issue open and commit it when D6 version of this module is ready.
#3
Thanks for the clarification. To get this into admin_menu for D5, we need a way to conditionally enable/load this stylesheet. Otherwise, it has to wait until a D6 port for admin_menu is ready.
#4
To get this into admin_menu for D5, we need a way to conditionally enable/load this stylesheet.
This is done at the theme layer. Existing solutions completely replace the original css with its rtl counterpart. If want to have this supported for D5 (for themes that implement this, like http://drupal.org/project/garlandrtl) use the attached as admin_menu-rtl.css (which is a copy of admin_menu.css with the RTL changes in the previous attachment). Don't forget the new PNG from the top of this issue.
#5
Here is a fuller file which worked for me.
Please commit the two files attached - admin_menu-rtl.css and arrow-rtl.css - into the 5.x version, even though they are beta quality - so people won't have to manually install it. This way we will get more feedback. Please put admin_menu-rtl.css in the main module's directory and arrow-rtl.png in the images directory.
No code changes are needed - the files are automatically used by RTL-aware themes.
Thanks in advance,
Amnon
-
Professional: Drupal Israel | Drupal Development & Consulting | Eco-Healing
Personal: Hitech Dolphin: Regain Simple Joy :)
#6
Not so fast....
In IE, it doesn't work as expected.
The secondary menus have a large left offser.
#7
Please test attached stylesheet.
#8
#7 works correctly for FF3 and Konqueror 3.5.8.
With Opera 9.5 all menus are at the right edge of the screen (see screenshot attached of the "Site Configuration" menu)
#9
After a lot of help from tombigel, we managed to create the RTL version of this CSS, which was tested to work for IE, Opera and FF.
I am attaching admin_menu-rtl.css, and reattaching arrow-rtl.png - the previous one had an issue with IE.
The RTL'ed CSS now only lists the differences from the main CSS, as is usually done for Drupal 6.x.
There is no change to the original CSS, so this does not change any of the LTR behavior of this module. Therefore, no patch attached, only new files (which are used automatically by Drupal if exists).
#10
Thanks, tested, fixed a few styles, and committed!
#11
Thanks for the fix - It works fantastically under Firefox, Safari and Google Chrome.
There is a need for a slight improvement for explorer 6+7 - all submenus are slided left. Submenus appear exactly one menu item to the left of the original menu item.
See attached image for demo.
#12
@levavie: does you comment regarding IE shifted menus relate to the patch in #10 or in #9? Can you please check again with #9 and let us know if there is a difference (between #9 and #10)? I don't have access to IE myself..
#13
Thanks to codeweavers for their lame duck presidential challenge, I got myself a working IE6 install.
I can confirm that the dev version behaves differently for IE6 - in IE6 the expanded menus are shifted to the left. The patch in #9 works correctly, so probably one of the adjustment made for #10 broke it.
#14
Please test whether attached patch fixes this. It's the only difference between #9 and #10, which should have an effect at all.
#15
Thats it!
Thanks.
#16
Thanks for testing!
#17
It's OK now
Thanks
#18
Automatically closed -- issue fixed for two weeks with no activity.