Are you, in fact, a pregnant lady who lives in the apartment next door to Superdeath's parents? - Commodore

Create an account  

 
RBClassic Themes Comment/Issue Thread

See above re: my ideas w/r/t using pixel measurements in stylesheets. Hate 'em. They limit things, y'know.

So on a lark, I went and did a few search-and-replaces in RBClassic's global.css, replacing the large pixel measurements (over 10px; my usual 5px barrier would have been a bit more complex wink ) with rough equivalents in ems, to make things a little more fluid. (For those who don't know, 1em == the font-size of the parent element. For body{}, which has a font-size of 13px, 1em == 13px.)

Those replacements were as follows:
10px->0.75em
11px->0.85em
12px->0.9em
13px->1em
15px->1.25em
16px->1.25em
20px->1.5em
22px->1.75em
24px->2em
200px->15.25em
750px->58em

Other changes made:
* "min-width: 1000px" in body{} is removed entirely. No point to it I can see beyond enforcing horizontal scrolling, which is a massive no-no. Let people with dinky browser windows pay the price. smile
* "width: 93%" in .wrapper{} is replaced with "max-width: 80em;". 80em (with a 13px font size) is roughly equivalent to 1040px, but can adjust with browser font sizes. This keeps the forum width from growing unnaturally with browser window size.
* A new declaration is added: ".smalltext .smalltext { font-size: 1em; }". This is because the current code nests smalltext classes, which makes some things (particularly subject lines on posts) appear unnaturally small with this scheme.
* "background-color: #fff;" in .codeblock{} becomes "background-color: #0A4646; color: #ddd;" (borrowed from blockquote{}). This is just an oversight that makes [code] look like it's white text on white, which I discovered when previewing this post! lol

Before and after screenshots:
Note: My browser's default font size is really rather large (16px!) because everybody and their idiot brother loves to specify smaller-than-average font sizes, and while I can read small text just fine, I find it annoying - especially in the last few years, when my primary machine is a laptop with a 15" 1920x1200 display. SO MUCH HATE. Therefore, with the sample screenshots below I've changed the body{} font-size temporarily to 13px, with one exception.

And yes, I use a lot of tabs. Sue me. :P wink

Widescreen look, before and after these changes:




Note that text doesn't get so stretched out that you end up with long long lines that are hard to read.

Compact look, before and after these changes:




No more horizontal scrollbar!

And just so we can see how it scales to browser preferences, here's the "widescreen" shot with my browser's usual 16px default font size:



The resulting global.css:
Code:
body {
    background: url(../../../images/RBClassic/bgRBClassic.png);
    color: #f00;
    text-align: center;
    line-height: 1.4;
    margin: 0;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
    font-size: 1em;
}

a:link {
    color: #e0e0f6;
    text-decoration: none;
}

a:visited {
    color: #e0e0f6;
    text-decoration: none;
}

a:hover, a:active {
    color: #e0e0f6;
    text-decoration: underline;
}


#container {
    color: #000;
    text-align: left;
    line-height: 1.4;
    margin: 0;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
    font-size: 1em;
}

.wrapper {
    max-width: 80em;
    min-width: 1px;
    margin: auto auto;
}

#logo {
    background: #385947 url(../../../images/RBClassic/HeaderBG.jpg) top left repeat-x;
    border-bottom: 1px solid #124A4A;
}

#content {
    background: #124A4A;
    width: auto !important;
    color: #dddddd;
    padding: 1.5em 0.75em;
    border-bottom: 1px solid #000;
}

#panel ul.menu {
    margin: 0;
    padding: 0;
    list-style: none;
}

#panel ul.menu li {
    margin: 0 5px;
    display: inline;
}

#panel ul.menu li a {
    padding-left: 1.5em;
    background-repeat: no-repeat;
    background-position: left center;
}

#panel .upper ul.top_links {
    float: right;
    font-weight: bold;
}

#panel .upper ul.top_links a.search {
    background-image: url(../../../images/RBClassic/icons/search.gif);
}

#panel .upper ul.top_links a.memberlist {
    background-image: url(../../../images/RBClassic/icons/memberlist.gif);
}

#panel .upper ul.top_links a.calendar {
    background-image: url(../../../images/RBClassic/icons/calendar.gif);
}

#panel .upper ul.top_links a.help {
    background-image: url(../../../images/RBClassic/icons/help.gif);
}

#panel .upper a.logout {
    background: url(../../../images/RBClassic/icons/logout.gif) right no-repeat;
    padding-right: 1.5em;
    margin-left: 0.75em;
    
    font-weight: bold;
}

#panel .upper a.login,
#panel .upper a.lost_password {
    background: url(../../../images/RBClassic/icons/login.gif) no-repeat;
    padding-left: 1.5em;
    margin-left: 0.75em;
    
    font-weight: bold;
}

#panel .upper a.register {
    background: url(../../../images/RBClassic/icons/logout.gif) right no-repeat;
    padding-right: 1.5em;
    margin-left: 0.75em;
    font-weight: bold;
}

#panel .lower ul.panel_links {
    float: left;
}

#panel .lower ul.panel_links a.usercp {
    background-image: url(../../../images/RBClassic/icons/usercp.gif);
}

#panel .lower ul.panel_links a.modcp {
    background-image: url(../../../images/RBClassic/icons/modcp.gif);
}

#panel .lower ul.panel_links a.admincp {
    background-image: url(../../../images/RBClassic/icons/admincp.gif);
}

#panel .lower ul.user_links {
    float: right;
}

#panel .lower ul.user_links li a {
    padding: 0;
}

#panel .upper {
    background: url(../../../images/RBClassic/PannelUpperBG.jpg) repeat-x;
    color: #fff;
    border-top: 1px solid #444;
    border-bottom: 1px solid #000;
    padding: 7px;
}

#panel .upper a:link,
#panel .upper a:visited,
#panel .upper a:hover,
#panel .upper a:active {
    color: #fff;
}

#panel .lower {
    background: #124A4A url(../../../images/RBClassic/thead.png) repeat-x;
    color: #fff;
    border-top: 1px solid #000;
    border-bottom: 1px solid #000;
    overflow: hidden;
    padding: 5px;
}

#panel .lower a:link,
#panel .lower a:visited {
    color: #c8c8c8;
}

#panel .lower a:hover,
#panel .lower a:active {
    color: #fff;
    text-decoration: none;
}

#panel .remember_me input {
    vertical-align: middle;
    margin: -3px 0 0 5px;
}

#panel input {
    margin: -3px 0;
}

#panel input.button {
    padding: 0;
}

#footer ul.menu {
    margin: 0;
    padding: 0;
    list-style: none;
}

#footer ul.menu li {
    margin: 0 5px;
    display: inline;
}

#footer .upper {
    background: url(../../../images/RBClassic/PannelUpperBG.jpg) repeat-x;
    border-bottom: 1px solid #006666;
    padding: 6px;
    overflow: hidden;
    
    font-size: 0.9em;
}

#footer a:link,
#footer a:visited {
    color: #ddd;
}

#footer a:hover,
#footer a:active {
    color: #fff;
    text-decoration: none;
}

#footer .upper .language {
    float: right;
    margin: -2px;
}

#footer .upper .language select {
    border-color: #000;
}

#footer .upper ul.bottom_links {
    float: left;
    margin: 3px 0 0 -5px;
}

#footer .lower {
    background: url(../../../images/RBClassic/thead.png) top left repeat-x;
    color: #dddddd;
    border-bottom: 3px solid #263c30;
    overflow: hidden;
    padding: 6px;
    
    font-size: 0.85em;
}

#footer .lower a:link,
#footer .lower a:visited {
    color: #dddddd;
}

#footer .lower a:hover,
#footer .lower a:active {
    color: #dddddd;
    text-decoration: underline;
}

#footer .lower #current_time {
    float: right;
}

fieldset {
    border: 1px solid #ddd;
}

table {
    color: #dddddd;
    font-size: 1em;
}

.tborder {
    background: #007777;
    width: 100%;
    margin: auto auto;
    border: 1px solid ##007777;
    padding: 1px;
}

.thead {
    background: url(../../../images/RBClassic/thead.png) top left repeat-x;
    color: #dddddd;
    border-bottom: 1px solid #263c30;
    padding: 8px;
}

.thead a:link {
    color: #ffffff;
    text-decoration: none;
}

.thead a:visited {
    color: #ffffff;
    text-decoration: none;
}

.thead a:hover, .thead a:active {
    color: #ffffff;
    text-decoration: underline;
}

.tcat {
    background: #0f0f0f url(../../../images/RBClassic/tcat.png) repeat-x;
    color: #fff;
    border-top: 1px solid #444;
    border-bottom: 1px solid #000;
    padding: 6px;
    
    font-size: 0.9em;
}

.tcat a:link {
    color: #fff;
}

.tcat a:visited {
    color: #fff;
}

.tcat a:hover, .tcat a:active {
    color: #fff;
}

.trow1 {
    background: #0A4646;
    border: 1px solid;
    border-color: #007777 #007777 #007777 #007777;
}

.trow2 {
    background: #0A3737;
    color: #ffffff;
    border: 1px solid;
    border-color: #007777 #007777 #007777 #007777;
}

.trow_shaded {
    background: #ffdde0;
    border: 1px solid;
    border-color: #ccc #ffb8be #ffb8be #ccc;
}

.trow_selected td {
    background: #FFFBD9;
    color: #f00;
    border-right-color: #F7E86A;
    border-bottom-color: #F7E86A;
}

.trow_selected td a:link,
.trow_selected td a:visited,
.trow_selected td a:hover,
.trow_selected td a:active {
    color: #000;
}

.trow_sep {
    background: #131313;
    color: #fff;
    border-bottom: 1px solid #121212;
    padding: 6px;
    
    font-size: 0.9em;
    font-weight: bold;
}

.tfoot {
    background:  url(../../../images/RBClassic/thead.png) top left repeat-x;
    color: #ffffff;
    border-top: 1px solid #124A4A;
    padding: 6px;
}

.tfoot a:link {
    color: #dddddd;
    text-decoration: none;
}

.tfoot a:visited {
    color: #dddddd;
    text-decoration: none;
}

.tfoot a:hover, .tfoot a:active {
    color: #ffffff;
    text-decoration: underline;
}

.thead input.textbox,
.thead select,
.tfoot input.textbox,
.tfoot select {
    border: 1px solid #263c30;
}

.bottommenu {
    background: #efefef ;
    color: #dddddd;
    border: 1px solid #4874a3;
    padding: 0.75em;
}

.navigation {
    color: #cccccc;
    font-size: 0.9em;
}

.navigation a:link {
    color: #cccccc;
    text-decoration: none;
}

.navigation a:visited {
    color: #cccccc;
    text-decoration: none;
}

.navigation a:hover, .navigation a:active {
    color: #fff;
    text-decoration: none;
}

.navigation .active {
    color: #fff;
    font-size: small;
    font-weight: bold;
}

.smalltext {
    font-size: 0.85em;
}
.smalltext .smalltext {
    font-size: 1em;
}

.largetext {
    font-size: 1.25em;
    font-weight: bold;
}

input.textbox {
    background: #0A3737;
    color: #fff;
    border: 1px solid #000;
    padding: 3px;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
}

textarea {
    background: #0A3737;
    color: #ffffff;
    border: 1px solid #666666;
    padding: 2px;
    line-height: 1.4;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
    font-size: 1em;
}

select {
    background: #0A3737;
    color: #ffffff;
    padding: 3px;
    border: 1px solid #000;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
}

input.button {
    padding: 2px;
    cursor: pointer;
    
    font-family: Tahoma, Verdana, Arial, Sans-Serif;
}

.editor {
    background: #f1f1f1;
    border: 1px solid #ccc;
}

.editor_control_bar {
    background: #f1f1f1;
    border: 1px solid #ccc;
}

.autocomplete {
    background: #ffffff;
    color: black;
    border: 1px solid #ccc;
    padding: 1px;
}

.autocomplete_selected {
    background: #48715b;
    color: #fff;
}

.popup_menu {
    background: #fff;
    border: 1px solid #ccc;
}

.popup_menu .popup_item {
    background: #efefef;
    color: #000;
}

.popup_menu .popup_item:hover {
    background: #48715b;
    color: #fff;
}

.trow_reputation_positive {
    background: #ccffcc;
}

.trow_reputation_negative {
    background: #ffcccc;
}

.reputation_positive {
    color: green;
}

.reputation_neutral {
    color: #444;
}

.reputation_negative {
    color: red;
}

.invalid_field {
    border: 1px solid #f30;
    color: #f30;
}

.valid_field {
    border: 1px solid #0c0;
}

.validation_error {
    background: url(../../../images/invalid.gif) no-repeat center left;
    color: #f30;
    margin: 5px 0;
    padding: 5px;
    font-weight: bold;
    font-size: 0.85em;
    padding-left: 1.75em;
}

.validation_success {
    background: url(../../../images/valid.gif) no-repeat center left;
    color: #00b200;
    margin: 5px 0;
    padding: 5px;
    font-weight: bold;
    font-size: 0.85em;
    padding-left: 1.75em;
}

.validation_loading {
    background: url(../../../images/spinner.gif) no-repeat center left;
    color: #555;
    margin: 5px 0;
    padding: 5px;
    font-weight: bold;
    font-size: 0.85em;
    padding-left: 1.75em;
}

/* Additional CSS (Master) */
img {
    border: none;
}

.clear {
    clear: both;
}

.hidden {
    display: none;
    float: none;
    width: 1%;
}

.hiddenrow {
    display: none;
}

.selectall {
    background: #FFFBD9;
    color: #000;
    border-bottom: 1px solid #F7E86A;
    text-align: center;
}

.float_left {
    float: left;
}

.float_right {
    float: right;
}

.expcolimage {
    background: #f1f1f1;
    width: auto;
    float: right;
    vertical-align: middle;
    margin-top: 3px;
}

img.attachment {
    border: 1px solid #E9E5D7;
    padding: 2px;
}

hr {
    color: #000000;
    background-color: #dddddd;
    height: 1px;
    border: 0px;
}

#debug {
    float: right;
    text-align: right;
    margin-top: 1.5em;
    
    font-size: 0.85em;
}

blockquote {
    background: #0A4646;
    color: #ddd;
    border-left: 5px solid #1C6D6D;
    margin: 0;
    padding: 4px;
}

blockquote cite {
    font-weight: bold;
    border-bottom: 1px solid #ccc;
    font-style: normal;
    display: block;
    margin: 4px 0;
}

blockquote cite span {
    float: right;
    font-weight: normal;
}

blockquote cite span.highlight {
    float: none;
    font-weight: bold;
    padding-bottom: 0;
}

.codeblock {
    background: #0A4646;
    color: #ddd;
    border: 1px solid #ccc;
    padding: 4px;
}

.codeblock .title {
    border-bottom: 1px solid #ccc;
    font-weight: bold;
    margin: 4px 0;
}

.codeblock code {
    overflow: auto;
    height: auto;
    max-height: 15.25em;
    display: block;
    font-family: Monaco, Consolas, Courier, monospace;
    font-size: 1em;
}

.subforumicon {
    border: 0;
    vertical-align: middle;
}

.separator {
    margin: 5px;
    padding: 0;
    height: 0px;
    list-style-type: none;
    
    font-size: 1px;
}

form {
    margin: 0;
    padding: 0;
}

.popup_menu .popup_item_container {
    margin: 1px;
    text-align: left;
}

.popup_menu .popup_item {
    display: block;
    padding: 4px;
    white-space: nowrap;
    
    text-decoration: none;
}

.popup_menu a.popup_item:hover {
    text-decoration: none;
}

.autocomplete {
    text-align: left;
}

.subject_new {
    font-weight: bold;
}

.highlight {
    background: #FFFFCC;
    padding-top: 3px;
    padding-bottom: 3px;
}

.pm_alert {
    background: #FFF6BF;
    border: 1px solid #FFD324;
    text-align: center;
    padding: 5px 1.5em;
    margin-bottom: 1.25em;
    font-size: 0.85em;
}

.red_alert {
    background: #FBE3E4;
    border: 1px solid #A5161A;
    color: #A5161A;
    text-align: center;
    padding: 5px 1.5em;
    margin-bottom: 1.25em;
    font-size: 0.85em;
}

.high_warning {
    color: #CC0000;
}

.moderate_warning {
    color: #F3611B;
}

.low_warning {
    color: #AE5700;
}

div.error {
    background: #1E1E1E;
    padding: 5px 0.75em;
    border-top: 2px solid #000000;
    border-bottom: 2px solid #000000;
    
    font-size: 0.9em;
}

div.error p {
    color: #f00;
    margin: 0;
    
    font-weight: normal;
}

div.error p em {
    background: url(../../../images/error.gif) no-repeat 0;
    color: #ff3333;
    padding-left: 2em;
    display: block;
    
    font-style: normal;
    font-weight: bold;
}

div.error.ul {
    margin-left: 2em;
}

.online {
    color: #D7A84C;
}

.offline {
    color: #c7c7c7;
}

.pagination {
    font-size: 0.85em;
    padding-top: 0.75em;
    margin-bottom: 5px;
}

.tfoot .pagination, .tcat .pagination {
    padding-top: 0;
}

.pagination .pages {
    font-weight: bold;
}

.pagination .pagination_current, .pagination a {
    background: #238FA3;
    padding: 3px 6px;
    margin-bottom: 3px;
}

.pagination a {
    background: #19646E;
    border: 1px solid #19646E;
}

.pagination .pagination_current {
    color: #fff;
    border: none;
    
    font-weight: bold;
}

.pagination a:hover {
    background: #1E8296;
    color: #fff;
    border-color: #1E788C;
    
    text-decoration: none;
}

.thread_legend, .thread_legend dd {
    margin: 0;
    padding: 0;
}

.thread_legend dd {
    padding-bottom: 4px;
    margin-right: 1.25em;
}

.thread_legend img {
    margin-right: 4px;
    vertical-align: bottom;
}

.forum_legend, .forum_legend dt, .forum_legend dd {
    margin: 0;
    padding: 0;
}

.forum_legend dd {
    float: left;
    margin-right: 0.75em;
    margin-top: 7px;
}

.forum_legend dt {
    margin-right: 0.75em;
    float: left;
}

.success_message {
    color: #00b200;
    font-weight: bold;
    font-size: 0.75em;
    margin-bottom: 0.75em;
}

.error_message {
    color: #C00;
    font-weight: bold;
    font-size: 0.75em;
    margin-bottom: 0.75em;
}

.post_body {
    padding: 5px;
}

.post_buttons {
    background: #1e1e1e;
    padding: 3px 3px 0 3px;
    border-bottom: 1px solid #1e1e1e;
}

.post_content {
    padding: 5px 0.75em;
}

.quick_jump {
    background: url(../../../images/jump.gif) no-repeat 0;
    width: 1em;
    height: 1em;
    padding-left: 1em; /* amount of padding needed for image to fully show */
    vertical-align: middle;
    border: none;
}

.repbox {
    font-size:1.25em;
    font-weight: bold;
    padding:5px 7px 5px 7px;
}

._neutral {
    background-color:#FAFAFA;
    color: #999999;
    border:1px solid #CCCCCC;
}

._minus {
    color: #CB0200;
    background-color: #FDD2D1f;
    border: 1px solid #980201;
}

._plus {
    background-color:#E8FCDC;
    color: #008800;
    border:1px solid #008800;
}

.pagination_breadcrumb {
    background-color: #efefef;
    border: 1px solid #fff;
    outline: 1px solid #ccc;
    padding: 5px;
    margin-top: 5px;
    
    font-weight: normal;
}

.pagination_breadcrumb_link {
    vertical-align: middle;
    cursor: pointer;
}

form #message {
    width: 58em;
}

.administrator_name {
color: white;
font-weight: bold;
font-style: italic;
}

HTH.
Participant in:
PBEM45, "Greens" Division (Sury of Carthage)
RB Demogame 1 pirate
Reply

Oh, and while I'm here - getting rid of the "Thread Icons" column has also kind of broken zakalwe's "block spoiler threads" Greasemonkey script.
EDIT: Don't worry about this in particular. Workin' on a fix myself.
Participant in:
PBEM45, "Greens" Division (Sury of Carthage)
RB Demogame 1 pirate
Reply

Removing min-width: 1000px is good, but I see no reason to enforce a forum width of 80em. If I have a larger resolution and my window is larger, I want a larger forum. Percentage width is fine.
Reply

(October 23rd, 2012, 13:55)NobleHelium Wrote: Removing min-width: 1000px is good, but I see no reason to enforce a forum width of 80em. If I have a larger resolution and my window is larger, I want a larger forum. Percentage width is fine.

I was going to say this too; I think we want versatility both ways, both in allowing the forums to shrink for small screens, and allowing them to grow for big screens. I think a max-width is bad, especially when people are inserting screenshots that would overflow a max-width anyways.

Otherwise, nice work Viqsi, I'll look to implementing most of this and see if that helps.
Reply

(October 23rd, 2012, 14:01)BRickAstley Wrote: I think we want versatility both ways, both in allowing the forums to shrink for small screens, and allowing them to grow for big screens. I think a max-width is bad, especially when people are inserting screenshots that would overflow a max-width anyways.

dito

Nice work Viqsi. I will let BRick get at it and see what happens, then we can also implement and fix the other themes too.


KoP
Reply

Please keep the current 100% width of .wrapper, thanks. :D If you must, I could also live with 98-97% width.
Reply

(October 23rd, 2012, 13:55)NobleHelium Wrote: Removing min-width: 1000px is good, but I see no reason to enforce a forum width of 80em. If I have a larger resolution and my window is larger, I want a larger forum. Percentage width is fine.

I tend to avoid that because it makes lines really really long, which can make them harder to read. But I suppose I can always throw in my own user stylesheet if I feel the need to be dogmatic on the point. :D


EDIT: In case anyone else is like me and prefers a slightly restricted max width...
Code:
body { background: #124A4A !important; }
#content { max-width: 80em !important; margin: auto !important; }

Throw that in a RB-specific user stylesheet (how to do that is browser-dependent, alas) and there you go.
Participant in:
PBEM45, "Greens" Division (Sury of Carthage)
RB Demogame 1 pirate
Reply

Okay, the em measurements are now in place of the px measurements. How does that look?
Reply

(October 23rd, 2012, 14:24)BRickAstley Wrote: Okay, the em measurements are now in place of the px measurements. How does that look?

There's no "whitespace" (okay, greenspace lol) on the sides. Some seem to like it that way. Maybe add a "padding: 0 5em;" to #content or .wrapper? That approximates the 93% width that was in there before. Can do smaller if that'll give Noble a conniption fit or something. wink
(If you add it to #content, you'll also want to add "body { background: #124A4A; }" because it turns up looking weird otherwise.)

Seems fine otherwise.


EDIT: Added post quote. Y'know, quickreply on other boards I frequent can actually reply to and quote another post. I've apparently gotten way way too used to that. frown
Participant in:
PBEM45, "Greens" Division (Sury of Carthage)
RB Demogame 1 pirate
Reply

The reply button on the post you're quoting should do that, unless I'm misunderstanding you.
Reply



Forum Jump: