Hi CiccioCB,
fortunately you found a possibility to include the code=annex window in the forum.
That works best with short code snippets, but finds its limmitations in readabylity if the code has more than 100 lines.
In the old forum we could paste the syntax-colored code with its window hight from the toolkit. That is not supportet by bbCode now.
I did not find a hint for a solution at my first quick internet search.
Code window in forum posts
- cicciocb
- Site Admin
- Posts: 2095
- Joined: Mon Feb 03, 2020 1:15 pm
- Location: Toulouse
- Has thanked: 450 times
- Been thanked: 1385 times
- Contact:
Re: Code window in forum posts
Hi Peter,
I experimented with the addition of another bbcode
I included [height=xxx] [/height] to limit the height of the text.
For that you can include this around the [code) bbcode.
Example of code as before
And the same limited to 200 pixels
Another solution could be to limit automatically at a given height.
This is probably the best choice but I need to investigate how do it (probably in the php code)
I experimented with the addition of another bbcode
I included [height=xxx] [/height] to limit the height of the text.
For that you can include this around the [code) bbcode.
Example of code as before
Code: [Local Link Removed for Guests]
onhtmlchange changeme
DTMF "0"
wait
freq:
print counter.freq(1), counter.freq(2)
return
butpress:
print "butpress", HtmlEventButton$
DTMF HtmlEventButton$
return
changeme:
print "changeme", HtmlEventVar$
return
sub DTMF(sim$)
local z
for z = 0 to 15
if (SYMB$(z) = ucase$(sim$)) then
pin.tone pin_T1, cols(z and 3)
pin.tone pin_T2, rows(z >> 2)
pause 2500 ' duration of the tone
pin.tone pin_T1, 0
pin.tone pin_T2, 0
exit for
end if
next z
end sub
Code: [Local Link Removed for Guests]
onhtmlchange changeme
DTMF "0"
wait
freq:
print counter.freq(1), counter.freq(2)
return
butpress:
print "butpress", HtmlEventButton$
DTMF HtmlEventButton$
return
changeme:
print "changeme", HtmlEventVar$
return
sub DTMF(sim$)
local z
for z = 0 to 15
if (SYMB$(z) = ucase$(sim$)) then
pin.tone pin_T1, cols(z and 3)
pin.tone pin_T2, rows(z >> 2)
pause 2500 ' duration of the tone
pin.tone pin_T1, 0
pin.tone pin_T2, 0
exit for
end if
next z
end sub
This is probably the best choice but I need to investigate how do it (probably in the php code)