Skip to content

Commit

Permalink
adjust styles on display page
Browse files Browse the repository at this point in the history
  • Loading branch information
sbryzak committed Jun 17, 2010
1 parent 160ec6d commit 9a799f6
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 33 deletions.
50 changes: 18 additions & 32 deletions jsf/pastecode/src/main/webapp/display.xhtml
Expand Up @@ -32,41 +32,27 @@
</ui:define>

<ui:define name="mainarea">
<div style="width: 100%; padding: 7px;">

<h:panelGrid columns="3" style="width: 80%; margin: 0px; padding: 0px;">
<div class="contentHeader">
Posted by #{pasteWindow.codeFragment.user} on #{pasteWindow.codeFragment.friendlyDate}
<div style="float:right">
<a href="download?id=#{pasteWindow.codeFragment.hash == null ? pasteWindow.codeFragment.id : pasteWindow.codeFragment.hash}" style="text-decoration: none;">DOWNLOAD</a>
</div>
</div>

<h:panelGroup>
<h:outputLabel for="user" value="User: "/>
<h:outputText id="user" maxlength="30" size="30" value="#{pasteWindow.codeFragment.user}"/>
</h:panelGroup>

<h:panelGroup>
<h:outputLabel for="theme" value="Choose theme: "/>
<h:selectOneMenu id="theme" value="#{pasteWindow.theme}" onchange="chooseStyle(this.value);"> <!-- this.form.submit() -->
<f:selectItems value="#{themes}" var="theme" itemLabel="#{theme.name}" itemValue="#{theme.name}" />
</h:selectOneMenu>
<a href="download?id=#{pasteWindow.codeFragment.hash == null ? pasteWindow.codeFragment.id : pasteWindow.codeFragment.hash}" style="text-decoration: none;"><input type="button" value="Download file" /></a>
</h:panelGroup>

<h:panelGroup style="text-align:right;">
<h:outputLabel for="unwrap" value="Unwrap code: "/>
<h:selectBooleanCheckbox id="unwrap" onchange="unwrap('codearea');"/>
</h:panelGroup>

</h:panelGrid>
<div class="formRow">
<h:outputLabel for="theme" value="Choose theme: "/>
<h:selectOneMenu id="theme" value="#{pasteWindow.theme}" onchange="chooseStyle(this.value);"> <!-- this.form.submit() -->
<f:selectItems value="#{themes}" var="theme" itemLabel="#{theme.name}" itemValue="#{theme.name}" />
</h:selectOneMenu>
</div>

<!--h:outputLabel for="unwrap" value="Unwrap code: "/>
<h:selectBooleanCheckbox id="unwrap" onchange="unwrap('codearea');"/-->

<h:outputText value="Pasted code: "/>
<div id="codearea" style="width:99%; border: 1px solid #7F7F7F; height:450px; overflow:scroll;">
<pre class="brush: #{pasteWindow.codeFragment.language.brush}">#{pasteWindow.codeFragment.text}</pre>
</div>

&nbsp;<br/>
<h:outputLabel for="note" value="Note: "/>
<div >
<h:outputText id="note" value="#{pasteWindow.codeFragment.note}"/>
</div>
<div id="codearea" style="width:99%; border: 1px solid #7F7F7F; height:450px; overflow:scroll;">
<pre class="brush: #{pasteWindow.codeFragment.language.brush}">#{pasteWindow.codeFragment.text}</pre>
</div>

</ui:define>

<ui:define name="rightmenu">
Expand Down
7 changes: 6 additions & 1 deletion jsf/pastecode/src/main/webapp/style/style.css
Expand Up @@ -98,6 +98,11 @@ div.contentHeader {
margin: 8px 4px 8px 4px;
}

div.contentHeader a, div.contentHeader a:visited, div.contentHeader a:hover {
font-weight: normal;
color: #ff0000;
}

/* General form styles */

.pastecode {
Expand All @@ -111,7 +116,7 @@ div.contentHeader {

div.formRow {
padding: 3px 4px 3px 2px;
clear: both;
/* clear: both;*/
}

div.formRow label {
Expand Down

0 comments on commit 9a799f6

Please sign in to comment.