Modify

Opened 23 months ago

Closed 3 months ago

Last modified 2 months ago

#13873 closed enhancement (fixed)

[PATCH] Make the wysiwyg-toolbar look a little nicer

Reported by: anonymous Owned by: Jun Omae
Priority: normal Component: TracWysiwygPlugin
Severity: normal Keywords: patch
Cc: Trac Release: 1.4

Description

I had this running (an older version of the plugin) with Trac 0.12, and with Trac 1.4.2 the text is a bit bigger, so the toolbar gets a bit mixed up. I also noticed the toolbar has trouble with the width when changing the browser zoom (below 100%) -- the toolbar icons would overflow the toolbar.

I made changes to wysiwyg.css to help with these items. See the comments in the changes below.

.wysiwyg-toolbar {
    display: table-cell;/* added to make the toolbar area perfectly wide */
    border: solid #d7d7d7;
    border-width: 1px 1px 1px 0;
    height: 18px;
    /* width: 400px; removed */
    float: left;
    -moz-user-select: none;
    -webkit-user-select: none;
}
.wysiwyg-toolbar li :link, .wysiwyg-toolbar li :visited {
    background: transparent url(toolbar.png) no-repeat;
    border: 1px solid #fff;
    border-left-color: #d7d7d7;
    cursor: default;
    display: block;
    width: 20px;
    height: 16px;
    color: #777;
    overflow-y: hidden; /* added just in case the text is too high */
}
.wysiwyg-toolbar li a#wt-style {
    width: 80px; /* changed from 62 to get text fully in toolbar */
    font-size: 90%; /* added to make text smaller to fit on toolbar better */
    white-space: nowrap;
    overflow-x: hidden;
    line-height: 1.2;
    padding-left: 2px;
    padding-right: 2px;
    background-image: url(../common/desc.png);
    background-position: right bottom;
}

Attachments (3)

tracwysiwygplugin_stylesheetsuggestions.patch (1.2 KB) - added by Dan 3 months ago.
Updated style suggestions, patch format.
WysiwygUpdatedLook.png (4.3 KB) - added by Dan 3 months ago.
The look of the toolbar with the previous patch.
WysiwygExistingLook.png (4.3 KB) - added by Dan 3 months ago.
The look of the toolbar without the previous patch.

Download all attachments as: .zip

Change History (9)

comment:1 Changed 23 months ago by figaro

Keywords: patch added

Changed 3 months ago by Dan

Updated style suggestions, patch format.

comment:2 Changed 3 months ago by Dan

I'm hardly a CSS wiz, but I came up with some mods to my original ideas. See the attached patch.

Changed 3 months ago by Dan

Attachment: WysiwygUpdatedLook.png added

The look of the toolbar with the previous patch.

comment:3 Changed 3 months ago by Dan

The look of the toolbar with the previous patch.

Changed 3 months ago by Dan

Attachment: WysiwygExistingLook.png added

The look of the toolbar without the previous patch.

comment:4 Changed 3 months ago by Dan

So, here's what it looks like before the patch. The selection area has an up-arrow that doesn't really do anything, and the text doesn't fit, so you can't really read it.

The look of the toolbar without the previous patch.

comment:5 Changed 3 months ago by Jun Omae

Resolution: fixed
Status: newclosed

In 18482:

TracWysiwygPlugin: use absolute length for font-size to fit toolbar height because font-size of root element is too large (closes #13873)

comment:6 Changed 2 months ago by Dan

Thanks!

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jun Omae.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.