RTL enhancements from Sewar. #3136

git-svn-id: https://develop.svn.wordpress.org/trunk@4258 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2006-09-27 00:51:17 +00:00
parent df5a935be4
commit 455dd7d763
13 changed files with 288 additions and 117 deletions

View File

@ -750,7 +750,7 @@ function _cat_row( $category, $level, $name_override = false ) {
$category->category_count = number_format( $category->category_count );
$category->link_count = number_format( $category->link_count );
return "<tr id='cat-$category->cat_ID'$class>
<th scope='row'>$category->cat_ID</th>
<th scope='row' style='text-align: center'>$category->cat_ID</th>
<td>" . ( $name_override ? $name_override : $pad . ' ' . $category->cat_name ) . "</td>
<td>$category->category_description</td>
<td align='center'>$category->category_count</td>
@ -778,7 +778,7 @@ function page_rows($parent = 0, $level = 0, $pages = 0, $hierarchy = true) {
$class = ('alternate' == $class) ? '' : 'alternate';
?>
<tr id='page-<?php echo $id; ?>' class='<?php echo $class; ?>'>
<th scope="row"><?php echo $post->ID; ?></th>
<th scope="row" style="text-align: center"><?php echo $post->ID; ?></th>
<td>
<?php echo $pad; ?><?php the_title() ?>
<?php if ('private' == $post->post_status) _e(' - <strong>Private</strong>'); ?>

View File

@ -89,12 +89,12 @@ $messages[4] = __('Category not added.');
<table class="widefat">
<thead>
<tr>
<th scope="col"><?php _e('ID') ?></th>
<th scope="col" style="text-align: left"><?php _e('Name') ?></th>
<th scope="col" style="text-align: left"><?php _e('Description') ?></th>
<th scope="col" width="90"><?php _e('Posts') ?></th>
<th scope="col" width="90"><?php _e('Bookmarks') ?></th>
<th colspan="2"><?php _e('Action') ?></th>
<th scope="col" style="text-align: center"><?php _e('ID') ?></th>
<th scope="col"><?php _e('Name') ?></th>
<th scope="col"><?php _e('Description') ?></th>
<th scope="col" width="90" style="text-align: center"><?php _e('Posts') ?></th>
<th scope="col" width="90" style="text-align: center"><?php _e('Bookmarks') ?></th>
<th colspan="2" style="text-align: center"><?php _e('Action') ?></th>
</tr>
</thead>
<tbody id="the-list">

View File

@ -155,12 +155,12 @@ $post_title = ('' == $post_title) ? "# $comment->comment_post_ID" : $post_title;
echo '<table class="widefat">
<thead>
<tr>
<th scope="col"><input type="checkbox" onclick="checkAll(document.getElementById(\'deletecomments\'));" /></th>
<th scope="col" style="text-align: left">' . __('Name') . '</th>
<th scope="col" style="text-align: left">' . __('E-mail') . '</th>
<th scope="col" style="text-align: left">' . __('IP') . '</th>
<th scope="col" style="text-align: left">' . __('Comment Excerpt') . '</th>
<th scope="col" colspan="3">' . __('Actions') . '</th>
<th scope="col" style="text-align: center"><input type="checkbox" onclick="checkAll(document.getElementById(\'deletecomments\'));" /></th>
<th scope="col">' . __('Name') . '</th>
<th scope="col">' . __('E-mail') . '</th>
<th scope="col">' . __('IP') . '</th>
<th scope="col">' . __('Comment Excerpt') . '</th>
<th scope="col" colspan="3" style="text-align: center">' . __('Actions') . '</th>
</tr>
</thead>';
foreach ($comments as $comment) {

View File

@ -31,11 +31,11 @@ if ($posts) {
<table class="widefat">
<thead>
<tr>
<th scope="col"><?php _e('ID') ?></th>
<th scope="col" style="text-align: left"><?php _e('Title') ?></th>
<th scope="col" style="text-align: left"><?php _e('Owner') ?></th>
<th scope="col" style="text-align: left"><?php _e('Updated') ?></th>
<th scope="col" colspan="3"><?php _e('Action'); ?></th>
<th scope="col" style="text-align: center"><?php _e('ID') ?></th>
<th scope="col"><?php _e('Title') ?></th>
<th scope="col"><?php _e('Owner') ?></th>
<th scope="col"><?php _e('Updated') ?></th>
<th scope="col" colspan="3" style="text-align: center"><?php _e('Action'); ?></th>
</tr>
</thead>
<tbody id="the-list">

View File

@ -73,7 +73,7 @@ if ( is_month() ) {
?>
</h2>
<form name="searchform" action="" method="get" style="float: left; width: 16em; margin-right: 3em;">
<form name="searchform" id="searchform" action="" method="get">
<fieldset>
<legend><?php _e('Search Posts&hellip;') ?></legend>
<input type="text" name="s" value="<?php if (isset($s)) echo wp_specialchars($s, 1); ?>" size="17" />
@ -85,7 +85,7 @@ if ( is_month() ) {
if ( count($arc_result) ) { ?>
<form name="viewarc" action="" method="get" style="float: left; width: 20em; margin-bottom: 1em;">
<form name="viewarc" id="viewarc" action="" method="get">
<fieldset>
<legend><?php _e('Browse Month&hellip;') ?></legend>
<select name='m'>
@ -112,7 +112,7 @@ if ( count($arc_result) ) { ?>
<?php } ?>
<form name="viewcat" action="" method="get" style="float: left; width: 30em; margin-bottom: 1em;">
<form name="viewcat" id="viewcat" action="" method="get">
<fieldset>
<legend><?php _e('Browse Category&hellip;') ?></legend>
<?php wp_dropdown_categories('show_option_all='.__('All').'&hide_empty=0&hierarchical=1&show_count=1&selected='.$cat);?>
@ -169,7 +169,7 @@ foreach($posts_columns as $column_name=>$column_display_name) {
case 'id':
?>
<th scope="row"><?php echo $id ?></th>
<th scope="row" style="text-align: center"><?php echo $id ?></th>
<?php
break;

View File

@ -104,13 +104,13 @@ printf(__('Currently showing %1$s links ordered by %2$s'), $select_cat, $select_
<table class="widefat">
<thead>
<tr>
<th width="15%" style="text-align: left"><?php _e('Name') ?></th>
<th style="text-align: left"><?php _e('URL') ?></th>
<th style="text-align: left"><?php _e('Categories') ?></th>
<th><?php _e('rel') ?></th>
<th><?php _e('Visible') ?></th>
<th colspan="2"><?php _e('Action') ?></th>
<th><input type="checkbox" onclick="checkAll(document.getElementById('links'));" /></th>
<th width="15%"><?php _e('Name') ?></th>
<th><?php _e('URL') ?></th>
<th><?php _e('Categories') ?></th>
<th style="text-align: center"><?php _e('rel') ?></th>
<th style="text-align: center"><?php _e('Visible') ?></th>
<th colspan="2" style="text-align: center"><?php _e('Action') ?></th>
<th style="text-align: center"><input type="checkbox" onclick="checkAll(document.getElementById('links'));" /></th>
</tr>
</thead>
<tbody id="the-list">

View File

@ -20,8 +20,8 @@ case 'update':
check_admin_referer('moderate-comments');
if ( ! current_user_can('moderate_comments') )
wp_die('<p>'.__('Your level is not high enough to moderate comments.').'</p>');
if ( !current_user_can('moderate_comments') )
wp_die(__('Your level is not high enough to moderate comments.'));
$item_ignored = 0;
$item_deleted = 0;

View File

@ -81,10 +81,10 @@ if (empty($plugins)) {
<table class="widefat">
<thead>
<tr>
<th style="text-align: left"><?php _e('Plugin'); ?></th>
<th><?php _e('Version'); ?></th>
<th style="text-align: left"><?php _e('Description'); ?></th>
<th><?php _e('Action'); ?></th>
<th><?php _e('Plugin'); ?></th>
<th style="text-align: center"><?php _e('Version'); ?></th>
<th><?php _e('Description'); ?></th>
<th style="text-align: center"><?php _e('Action'); ?></th>
</tr>
</thead>
<?php

View File

@ -1,113 +1,223 @@
body {
direction: rtl;
#viewarc, #viewcat, #namediv, #emaildiv, #uridiv, #planetnews li, #login ul li, #your-profile fieldset, .alignleft .available-theme {
float: right
}
#templateside, .alignright {
float: left;
}
#login, #send, .widefat th {
text-align: right
}
#postcustomsubmit, h2 small.quickjump, form#upload th, .submit, .editform th {
text-align: left
}
body, td {
font: 13px Tahoma, "Lucida Grande", "Lucida Sans Unicode", Verdana;
}
h2 small.quickjump {
text-align: left;
}
h2 small.quickjump a {
font-size: 12px;
font-family: Tahoma, sans-serif;
fieldset.options legend {
font-family: Tahoma, Georgia, "Times New Roman", Times, serif;
}
textarea, input, select {
font: 12px Tahoma, Arial, Helvetica, sans-serif;
font: 13px Tahoma, Verdana, Arial, Helvetica, sans-serif;
}
.quicktags, .search {
font: 12px Tahoma, Georgia, "Times New Roman", Times, serif;
}
.submit input, .submit input:focus, .button {
border-right-color: #ccc;
}
.submit input:active, .button:active {
border-right-color: #999;
}
.updated, .confirm {
padding: 0 3em 0 1em;
}
#adminmenu {
float: right;
width: 100%;
padding: .2em 2em .3em .2em;
height: 30px;
}
#adminmenu a {
font-size: 16px;
font-weight: bold;
font-family: georgia;
margin: 0px 2px;
padding: 1px 5px;
margin: 0 0 0 10px;
display: block;
float: right;
}
#submenu {
clear: both;
float: right;
width: 100%;
height: 21px;
padding: 3px 3em 0 2em;
}
#submenu .current {
border-left: 2px solid #045290;
}
#submenu a {
padding: .1em .33em;
padding: .3em .4em .33em .4em;
margin: 0 0 0 10px;
display: block;
float: right;
margin: 0px 2px;
}
#title {
font-family: georgia;
#submenu li {
line-height: 100%;
}
#postdiv , #titlediv, #guiddiv {
margin: 0 0 0 8px;
}
#currenttheme img {
float: right;
margin-right: auto;
margin-left: 1em;
}
#postdiv #quicktags {
padding-right: auto;
padding-left: 6px;
}
#quicktags #ed_toolbar {
padding: 0px 0 0 2px;
}
#ed_toolbar input {
margin: 3px 0 2px 2px;
}
* html #postexcerpt .dbx-toggle-open, * html #postexcerpt .dbx-toggle-open, #postexcerpt div, #attachmentlinks div {
padding-right: auto;
padding-left: 8px;
}
#login h1 {
direction: ltr;
left: auto;
right: 137px;
}
#postcustom .updatemeta, #postcustom .deletemeta {
width: 5em;
#login h1 a {
display: none;
}
#searchform {
float: right;
margin-right: auto;
margin-left: 3em;
}
#poststuff {
margin-right: auto;
margin-left: 16em;
}
#template div {
direction: ltr;
margin-right: auto;
margin-left: 190px;
}
* html #template div {
margin-right: auto;
margin-left: 0px;
}
#user_info {
left: 1em;
top: 0;
right: auto;
left: 1em;
}
#wphead {
padding: .8em 2em .8em 19em;
}
#wphead h1 {
font-size: 2.4em;
font-family: Tahoma, Georgia, "Times New Roman", Times, serif
}
#zeitgeist {
float: left;
margin-left: auto;
margin-right: 1em;
}
#zeitgeist ul {
margin: 0 .6em .3em 0;
padding: 0 .6em 0 0;
}
#moremeta fieldset div {
padding: 0 7px 0 0;
margin: 2px 0px 0 0;
}
#moremeta {
margin-right: auto;
margin-left: 15px;
right: auto;
left: 5%;
}
#categorydiv ul {
margin-left: auto;
margin-right: 10px;
}
#your-profile legend {
font-family: Tahoma, Georgia, "Times New Roman", Times, serif;
}
#moremeta .dbx-content {
background: url(images/box-butt.gif) no-repeat bottom left;
padding: 5px 10px 15px 5px;
padding-right: auto;
padding-left: 2px;
}
#moremeta .dbx-handle {
background: url(images/box-head.gif) no-repeat right;
background: #2685af url(images/box-head.gif) no-repeat left;
}
#moremeta .dbx-box {
background: url(images/box-bg.gif) repeat-y left;
}
/* toggle images */
a.dbx-toggle, a.dbx-toggle:visited {
left: 5px;
right: auto;
left: 2px;
}
#advancedstuff a.dbx-toggle, #advancedstuff a.dbx-toggle-open:visited {
right: auto;
left: 5px;
}
#advancedstuff a.dbx-toggle-open, #advancedstuff a.dbx-toggle-open:visited {
}
/* Ali ix Corrections and Additions ;) */
td.desc, td.name, textarea#ping_sites, textarea#moderation_keys, textarea#blacklist_keys, input#home, input#admin_email, input#siteurl, input#mailserver_url, input#mailserver_port, input#mailserver_login, input#mailserver_pass, input#blog_charset, input#permalink_structure, input#post_name, input#trackback {
direction: ltr;
text-align: left;
}
.mceToolbarTop {
direction: ltr;
right: auto;
left: 5px;
}
div#zeitgeist ul, div.wrap ul {
list-style: none;
}
table.widefat th, tr.thead {
text-align: right;
#categorychecklist {
margin-right: auto;
margin-left: 6px;
}
#ajax-response.alignleft {
margin-left: auto;
margin-right: 2em;
}
#postdivrich #edButtons {
padding-left: auto;
padding-right: 3px;
}
#edButtons input, #edButtons input:active {
margin: 0px 0 -1px 2px;
}

View File

@ -378,18 +378,18 @@ foreach($roleclasses as $role => $roleclass) {
<tr>
<?php if ( !empty($role) ) : ?>
<th colspan="7" align="left"><h3><?php echo $wp_roles->role_names[$role]; ?></h3></th>
<th colspan="7"><h3><?php echo $wp_roles->role_names[$role]; ?></h3></th>
<?php else : ?>
<th colspan="7" align="left"><h3><em><?php _e('No role for this blog'); ?></h3></th>
<th colspan="7"><h3><em><?php _e('No role for this blog'); ?></h3></th>
<?php endif; ?>
</tr>
<tr class="thead">
<th style="text-align: left"><?php _e('ID') ?></th>
<th style="text-align: left"><?php _e('Username') ?></th>
<th style="text-align: left"><?php _e('Name') ?></th>
<th style="text-align: left"><?php _e('E-mail') ?></th>
<th style="text-align: left"><?php _e('Website') ?></th>
<th colspan="2"><?php _e('Actions') ?></th>
<th><?php _e('ID') ?></th>
<th><?php _e('Username') ?></th>
<th><?php _e('Name') ?></th>
<th><?php _e('E-mail') ?></th>
<th><?php _e('Website') ?></th>
<th colspan="2" style="text-align: center"><?php _e('Actions') ?></th>
</tr>
</thead>
<tbody id="role-<?php echo $role; ?>"><?php

View File

@ -48,6 +48,10 @@ a.delete:hover {
padding: 5px 6px;
}
.widefat th {
text-align: left;
}
.import-system {
font-size: 16px;
}
@ -366,7 +370,7 @@ form#upload #post_content {
}
.updated, .confirm {
background: #CFEBF7 url(images/notice.gif) no-repeat 1em ;
background: #CFEBF7 url(images/notice.gif) no-repeat 1em;
border: 1px solid #2580B2;
margin: 1em 5% 10px;
padding: 0 1em 0 3em;
@ -514,12 +518,15 @@ table .vers {
border: 1px solid #ccc;
border-bottom: none;
}
#postdiv #quicktags {
padding-right: 6px;
}
#postdivrich #quicktags {
display: none;
}
#quicktags #ed_toolbar {
padding: 0px 2px;
}
@ -677,6 +684,24 @@ table .vers {
font-size: 1.2em;
}
#searchform {
float: left;
margin-right: 3em;
width: 16em;
}
#viewarc {
float: left;
width: 20em;
margin-bottom: 1em;
}
#viewcat {
float: left;
width: 30em;
margin-bottom: 1em;
}
#postcustom .updatemeta, #postcustom .deletemeta {
margin: auto;
}
@ -916,17 +941,20 @@ table .vers {
#categorydiv ul {
list-style: none;
padding: 0;
margin-left:10px;
margin-left: 10px;
}
#categorychecklist {
height: 12em;
overflow: auto;
margin-top: 8px;
}
#categorychecklist li {
margin: 0;
padding: 0;
}
#ajaxcat input {
border: 1px solid #ccc;
}
@ -1111,8 +1139,13 @@ a.dbx-toggle, a.dbx-toggle:visited {
filter: alpha(opacity=80);
}
#newcat { width: 120px; margin-right: 5px; }
input#catadd { background: #a4a4a4;
#newcat {
width: 120px;
margin-right: 5px;
}
input #catadd {
background: #a4a4a4;
border-bottom: 1px solid #898989;
border-left: 1px solid #bcbcbc;
border-right: 1px solid #898989;
@ -1125,32 +1158,41 @@ input#catadd { background: #a4a4a4;
height: 20px;
margin-bottom: 2px;
text-align: center;
width: 37px; }
width: 37px;
}
#howto {
font-size: 11px;
margin: 0 5px;
display: block;
}
#jaxcat {
margin: 0;
padding: 0;
}
#ajax-response.alignleft {
margin-left: 2em;
}
#postdivrich #edButtons {
padding-left: 3px;
}
#postdivrich #content, #postdivrich #content:active {
border: 1px solid #ccc;
}
#edButtons input, #edButtons input:active {
margin: 0px 2px -1px;
}
#edButtons input.edButtonFore, #edButtons input.edButtonFore:active {
background: #f0f0ee;
border-bottom: 1px solid #f0f0ee;
}
#edButtons input.edButtonBack, #edButtons input.edButtonBack:active {
background: #fff url( images/fade-butt.png ) repeat-x 0px 15px;
border-bottom: 1px solid #ccc;

View File

@ -1161,12 +1161,16 @@ function wp_die($message, $title = '') {
function _mce_set_direction() {
global $wp_locale;
if ('rtl' == $wp_locale->text_direction)
if ('rtl' == $wp_locale->text_direction) {
echo 'directionality : "rtl" ,';
echo 'theme_advanced_toolbar_align : "right" ,';
}
}
function _mce_load_rtl_plugin($input) {
global $wp_locale;
if ('rtl' == $wp_locale->text_direction)
$input[] = 'directionality';
@ -1175,6 +1179,7 @@ function _mce_load_rtl_plugin($input) {
function _mce_add_direction_buttons($input) {
global $wp_locale;
if ('rtl' == $wp_locale->text_direction) {
$new_buttons = array('separator', 'ltr', 'rtl');
$input = array_merge($input, $new_buttons);

View File

@ -1,13 +1,13 @@
<?php
require_once('../../../wp-config.php');
?>
<?php require_once('../../../wp-config.php'); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
<head>
<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" />
<title><?php _e('Rich Editor Help') ?></title>
<link rel="stylesheet" href="<?php echo get_option('siteurl') ?>/wp-admin/wp-admin.css?version=<?php bloginfo('version'); ?>" type="text/css" />
<?php if ( ('rtl' == $wp_locale->text_direction) ) : ?>
<link rel="stylesheet" href="<?php echo get_option('siteurl') ?>/wp-admin/rtl.css?version=<?php bloginfo('version'); ?>" type="text/css" />
<?php endif; ?>
<style type="text/css">
#wphead {
padding-top: 5px;
@ -78,6 +78,20 @@ require_once('../../../wp-config.php');
border-bottom: 0px;
}
</style>
<?php if ( ('rtl' == $wp_locale->text_direction) ) : ?>
<style type="text/css">
#wphead, #adminmenu {
padding-left: auto;
padding-right: 15px;
}
#flipper {
margin: 5px 0 3px 10px;
}
#keys .left, .top, .action { text-align: right; }
#keys .right { text-align: left; }
td b { font-family: Tahoma, "Times New Roman", Times, serif }
</style>
<?php endif; ?>
<script type="text/javascript">
window.onkeydown = window.onkeypress = function (e) {
e = e ? e : window.event;