Code Blocks
This is the code block I use, it's stolen wholesale from somewhere else on the web, but I'm afraid I can't recall where. I'm still not fully happy with it, and I'll likely keep modifying it, but it works.Open up your Blogger page, go to template, customise, Advanced > Add CSS
And add the following code block:
.code { background:#f5f8fa; background-repeat:no-repeat; border: solid #5C7B90; border-width: 1px 1px 1px 20px; color: green ; font: 13px 'Courier New', Courier, monospace; line-height: 16px; margin: 10px 0 10px 10px; max-height: 200px; min-height: 16px; overflow: auto; padding: 28px 10px 10px; width: 90%; } .code:hover { background-repeat:no-repeat;}
Apply the template to your blog and you can use it whenever you wish. I stole it wholesale from somewhere else on the web... can't recall where I'm afraid. You can vary the colours, and any of the other options as you wish.To use it type your code in the compose window, switch to HTML and add <div class="code"> to the start of the block, and </div> to the end.
<div class="code">
#include
your code block here
# comments
</div>
#include
your code block here
# comments
</div>
Tables
Frame Only
|
Final Weight
| |
v1.0
|
588g
|
1.37kg
|
v2.0
|
271g
|
1.04kg
|
<table 100="" border="1" bordercolor="#0033FF" cellpadding="3" cellspacing="0" px="" tbody="" width:=""><tbody>
<tr><td><div style="text-align: center;">
<br /></div>
</td><td><div style="text-align: center;">
Frame Only</div>
</td><td><div style="text-align: center;">
Final Weight</div>
</td></tr>
<tr><td><div style="text-align: center;">
v1.0</div>
</td><td><div style="text-align: center;">
588g</div>
</td><td><div style="text-align: center;">
1.37kg</div>
</td></tr>
<tr><td><div style="text-align: center;">
v2.0</div>
</td><td><div style="text-align: center;">
271g</div>
</td><td><div style="text-align: center;">
1.04kg<br />
<div>
<br />
</div>
</div>
</td></tr>
</tbody></table>
<tr><td><div style="text-align: center;">
<br /></div>
</td><td><div style="text-align: center;">
Frame Only</div>
</td><td><div style="text-align: center;">
Final Weight</div>
</td></tr>
<tr><td><div style="text-align: center;">
v1.0</div>
</td><td><div style="text-align: center;">
588g</div>
</td><td><div style="text-align: center;">
1.37kg</div>
</td></tr>
<tr><td><div style="text-align: center;">
v2.0</div>
</td><td><div style="text-align: center;">
271g</div>
</td><td><div style="text-align: center;">
1.04kg<br />
<div>
<br />
</div>
</div>
</td></tr>
</tbody></table>
- To add or remove rows: remove the entire code between <tr> and </tr> (start/stop TableRow)
- To add or remove columns: remove cells, <td> to </td>
- Borders only change when page is previewed
- Cell padding is inside borders
- Cell spacing is between cells
- Tables in code are ugly, and Blogger doesn't keep your formatting, so it has to be redone each time
Other Tips and Tricks
- Alt+Print Screen on a win 7 or 8 machine does a screen cap of just the active window, so you don't need to make the rest of your desktop presentable.
- Multiple monitors are a god-send, always.
No comments:
Post a Comment