source: branches/1.1dev/css/utilities.inc.css @ 306

Last change on this file since 306 was 306, checked in by quinn, 16 years ago

Adding some needed form css.

File size: 3.1 KB
Line 
1/**
2 * utilities.css
3 * code by strangecode :: www.strangecode.com :: this document contains copyrighted information
4 *
5 * CSS used often in Strangecode applications. Do not arbitrarily
6 * edit this code! This file is used between many sites and modifying it may result
7 * in something breaking. Instead, overwrite these values in a specific site by
8 * adding new definitions to a screen.css file.
9 */
10
11/* BEAU: I format my CSS using BBEdit's Markup->CSS->Format command. Would you like to use that as well so our code looks consistant? */
12
13/*_____________________ FORMS ____________________*/
14input, select, input.submit
15{
16    color: #000;
17    margin: 0 4px 0 0;
18    padding: 0;
19}
20
21/* BEAU: I changed this to input.submit, since it is an <input> tag. Is that correct? It definition doesn't seem to do anything regardless of how it's set. */
22input.submit
23{
24    font-weight: bold;
25    margin: 1px;
26}
27
28/* BEAU: Should be in EMs? Also, sometimes it is nice to have the select menu be only the width as its contents. How to override this? */
29select
30{
31    width: 250px;
32    margin: 4px 4px 0 0;
33}
34
35input
36{
37    margin: 4px 4px 0 0;
38}
39
40form table select, form table input
41{
42    margin-top: 0;
43}
44
45/*
46BEAU: I want more text box widths! I find need for boxes that fit 5em, 10em, 20em, and 40em widths. These should be in EMs so text can resize and still fit. Since it is useful to apply a width to other form elements to have them similar sizes (not always a text box, such as <select multiple>) I propose renaming them to "input.tiny", "input.small", "input.medium", "input.large", and "input.half" (not sure how you would do "half" in EMs however.
47*/
48input.textwide, textarea.textwide
49{
50    width: 500px;
51}
52
53input.text, textarea.text
54{
55    width: 250px;
56}
57
58input.textsmall, textarea.textsmall
59{
60    width: 150px;
61}
62
63input.texthalf, textarea.texthalf
64{
65    width: 121px;
66    /*  125 minus 4 to account for the 4px padding on the right  */
67}
68
69/*textarea
70{
71    height: 8em;
72}*/
73
74/* BEAU: Again, here, "small", "medium", "large" denominations make sense. But how to diferentiate width from height? */
75textarea.twoliner
76{
77    height: 3em;
78}
79
80textarea.paragraphs
81{
82    height: 20em;
83}
84
85textarea.tall
86{
87    height: 40em;
88}
89
90form label
91{
92    font-weight: bold;
93}
94
95/* BEAU: We need a .formtext substitute...something like a label tag but not bold! */
96
97/*_____________________ COMMANDS ____________________*/
98#commandbox
99{
100    padding: 5px;
101    margin: 0 0 .5em 0;
102    border: black 1px dotted;
103    background-color: #DDD;
104}
105
106.commanditem
107{
108    margin: 0 10px 0 0;
109    white-space: nowrap;
110}
111
112.commandtext
113{
114    padding-right: 1em;
115}
116
117.command_left
118{
119    float:left; 
120    white-space: nowrap;
121}
122
123.command_right
124{
125    position: relative;
126    visibility: visible;
127    white-space: nowrap;
128    float:right; 
129}
130
131/*_____________________ UTILITIES ____________________*/
132.nowrap
133{
134    white-space: nowrap;
135}
136
137.clearboth
138{
139    clear: both;
140}
141
142.center
143{
144    text-align: center;
145}
146
147.right
148{
149    text-align: right;
150}
151
152.padright
153{
154    padding: 0 10px 0 0;
155}
156
157.padleft
158{
159    padding: 0 0 0 10px;
160}
161
162.help
163{
164    color: #999;
165    font-weight: normal;
166}
167
168.monospaced
169{
170    font-family: monaco, courier;
171    font-weight: normal;
172}
Note: See TracBrowser for help on using the repository browser.