Editing Template:Boxcodelite

Jump to navigation Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
<div style="float:{{{float|right}}}; margin:5px; padding:3px; font-size:0.85em; background:#f7c7a7; border:3px double #c79777; box-shadow: 4px 4px 2px 1px rgba(0,0,0,.2);">
<div style="float:right; margin-top:-28px; margin-right:10px; font-size:85%;"><div style="float:top; text-align:center; font-weight:bold;">{{{1|Please enter a title for this config}}}</div><div style="border:solid #eebb99 5px; box-shadow: 4px 4px 2px 1px #eeeeee;"><div style="margin-top:-12px; margin-bottom:-12px;">{{{2|Config}}}</div></div></div><noinclude>[[Category:Templates]]<noinclude>
{{#if:{{{title|}}} | <div style="margin-top:-3px; text-align:center; font-weight:bolder;">{{{title|Custom Title}}}</div> | }}
{{#ifeq:{{{syntax}}} | wiki | {{#tag:div|{{{code|Code Sample}}}|style="min-width:330px; padding:5px; background:{{{background|#f7f4f2}}}; color:{{{color|#000}}}; border:1px dashed #c79777; font-family:monospace; font-weight:bolder; font-size:1.2em; line-height:1.6em"}} | {{#tag:pre|{{{code|Code Sample}}}|style="min-width:330px; padding:5px; background:{{{background|#f7f4f2}}}; color:{{{color|#000}}}; border:1px dashed #c79777; line-height:1.1em"}}}}
{{#if:{{{ps2configrev|}}} | <div style="height:13px; text-align:left; font-size:0.9em;">{{ps2configrev|{{{ps2configrev|}}}}}</div> | }}
</div><noinclude>


{{clear}}
{{clear}}<br>
== Usage ==
== Usage ==
*<nowiki>{{</nowiki>boxcodelite|'''code'''=Code Sample<nowiki>}}</nowiki>
This template is intended to display a floating code box at right of the screen, if used repeatedly the code boxes will be aligned in the same row, are dsiplayed with a vertical displacement to top for an optimal usage of the space available, are supposed to be writen inmediatly after the page section name and any other informative text about what the config does should be written after the code boxes
*<nowiki>{{</nowiki>boxcodelite|'''title'''=Custom Title|'''code'''=Code Sample<nowiki>}}</nowiki>
*<nowiki>{{</nowiki>boxcodelite|'''float'''=left|'''title'''=Custom Title|'''code'''=Code Sample<nowiki>}}</nowiki>
*<nowiki>{{</nowiki>boxcodelite|'''syntax'''=wiki|'''float'''=left|'''title'''=Custom Title|'''code'''=Code Sample<nowiki>}}</nowiki>
*<nowiki>{{</nowiki>boxcodelite|'''syntax'''=wiki|'''background'''=#000|'''color'''=#fff|'''title'''=Custom Title|'''code'''=Code Sample<nowiki>}}</nowiki>
*<nowiki>{{</nowiki>boxcodelite|'''title'''=Custom Title|'''ps2configrev'''=17495|'''code'''=Code Sample<nowiki>}}</nowiki>


== Examples ==
*'''<nowiki>{{gameconfig|Title|Config}}</nowiki>'''
<div style="float:right">
**This way allows to display some plain text inside the box, consider it a "hack" that eventually could come in handy incase there are problems with the other modes, but better avoid it
{{boxcodelite|title=HEX view|code=
*'''<nowiki>{{gameconfig|Title|<pre>Config</pre>}}</nowiki>'''
01 FF C4 00 1E 00 00 01 04 03 01 01 01 00 00 00
**This displays the texts "preformatted", preserves linespaces, black monospace font on top of white background
00 00 00 00 00 00 04 02 03 05 06 01 07 08 00 09
*'''<nowiki>{{gameconfig|Title|<syntaxhighlight lang=bash>Config</syntaxhighlight>}}</nowiki>'''
0A FF C4 00 64 10 00 02 01 02 05 02 04 04 04 04
**This displays the texts with color highlights for the '''lang=[https://www.mediawiki.org/wiki/Extension:SyntaxHighlight#Supported_languages supported_programming_languages]''', if there is no language that fits use '''lang=[https://en.wikipedia.org/wiki/Bash_%28Unix_shell%29 bash]'''
04 05 00 01 00 2B 01 02 03 04 11 00 05 06 12 21
31 41 07 13 51 61 14 22 71 81 08 32 91 A1 15 23
B1 C1 16 42 D1 F0 09 17 24 33 E1 52 F1 18 25 43
62 26 34 72 92 27 53 82 A2 19 B2 28 35 44 54 55
63 93 C2 36 73 A3 D2 38 64 83 B3 0A 45 74 94 37
56 65 84 A4 C3 D3 B4 FF C4 00 1D 01 00 01 05 01
}}


{{boxcodelite|title=HEX view<br>(allows to use more than one text row in the title)|code=
01 FF C4 00 1E 00 00 01 04 03 01 01 01 00 00 00
00 00 00 00 00 00 04 02 03 05 06 01 07 08 00 09
0A FF C4 00 64 10 00 02 01 02 05 02 04 04 04 04
04 05 00 01 00 2B 01 02 03 04 11 00 05 06 12 21
31 41 07 13 51 61 14 22 71 81 08 32 91 A1 15 23
}}


{{clear|right}}
*When this template was created (august 2021) the <nowiki><syntaxhighlight></nowiki> extension is broken in this wiki, so the result of <nowiki><syntaxhighlight></nowiki> or <nowiki><pre></nowiki> is exactly the same, but better use the dislpay mode with the <nowiki><syntaxhighlight></nowiki> as a prevention because eventually the <nowiki><syntaxhighlight></nowiki> extension could be fixed


{{boxcodelite|title=BLJM85001|code=
== Examples ==
{{gameconfig|BLJM85001|<pre>
VERSION = 0xFFFFFFFF
VERSION = 0xFFFFFFFF
S3D.ENABLE = 2
S3D.ENABLE = 2
SDRAM_SIZE = 02800000
SDRAM_SIZE = 02800000
MIPS_CODE_BLOCK_SIZE = 8192
MIPS_CODE_BLOCK_SIZE = 8192
}}
</pre>}}


{{boxcodelite|title=SCES-50885|ps2configrev=17495|code=
{{gameconfig|BLJM85001|<syntaxhighlight lang=xml>
3D 00 00 00 57 44 00 00 0A 00 00 00 01 00 00 00
VERSION = 0xFFFFFFFF
E0 E0 34 00 16 00 40 14 00 00 00 00 00 00 00 00
S3D.ENABLE = 2
}}
SDRAM_SIZE = 02800000
 
MIPS_CODE_BLOCK_SIZE = 8192
{{clear|right}}
</syntaxhighlight>}}
 
{{boxcodelite|syntax=wiki|background=#000|color=#fff|title=Text highlight|code=<div style="margin-top:-7px; margin-bottom:-7px">
FF FF <span style="background:#ffff00;">00 00</span> 4D 14 <span style="background:#ff4040;">FF FF FF FF FF</span> <span style="background:#ff8080;">81 88 81 88 FF</span><br>
5A 00 5B 00 02 00 60 00 61 00 02 00 7D 00 7D 00<br>
02 00 FF FF FF FF FF FF FF FF FF FF FF FF <span style="background:#ffbbbb;">FF FF</span><br>
<span style="background:#ffbbbb;">FF FF FF</span> FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF<br>
FF FF <span style="background:#666;">00</span> <span style="color:#ff0;">4D 14</span> <span style="background:#666;">FF FF FF FF FF</span> <span style="background:#666;">FF FF 00 FF 00</span> <span style="background:#666;">FF</span><br>
<span style="background:#88f;">54 00</span> <span style="background:#88f;">55 00</span> <span style="background:#88f;">02 00</span> <span style="color:#f00;">5E 00 5F 00 02 00</span> FF FF FF FF<br>
02 00 <span style="color:#0f0;">46 00 47 00 02 00</span> FF FF FF FF 02 00 <span style="background:#666;">FF FF</span><br>
</div>}}
</div>
 
T
 
E
 
X
 
T
 
L
 
I
 
N
 
E
 
S


[[Category:Templates]]</noinclude>
[[Category:Templates]]</noinclude>
Please note that all contributions to PS3 Developer wiki are considered to be released under the GNU Free Documentation License 1.2 (see PS3 Developer wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following hCaptcha:

Cancel Editing help (opens in new window)

Templates used on this page: