You are here: PSPad forum > English discussion forum > Re: Question to the board highlighter

Re: Question to the board highlighter

#1 Question to the board highlighter

Posted by: human | Date: 04/10/2017 09:29 | IP: IP Logged

When addingsource in code tagall whitespaces within them are removed in the display.
To keep at least the line breaks the board generates multiple<br>elements but the indentation of code is still not recognizable.

I asume Petr Dvořák wrote the board code and he may be able to change this (but don't know for sure and wouldn't know how to contact him and how to update the board later on), therefore leaving the request here:

* don't generate any<br>or<p></p>in parts marked with "code"
* instead use the following style via css:code { white-space: pre; }

Options: Reply | Quote | Up ^


#2 Re: Question to the board highlighter

Posted by: pspad | Date: 04/10/2017 18:35 | IP: IP Logged

Petr Dvorak isn't available long time already.
I tried to fix CODE in forum myself. Test it.

Options: Reply | Quote | Up ^


#3 Re: Question to the board highlighter

Posted by: human | Date: 04/11/2017 08:08 | IP: IP Logged

Test 1


;PSPad user HighLighter definition file

[Settings]
Name=Texinfo
HTMLGroup=0
Vectors=0
Label=0

[KeyWords]
@acronym=
@b=
@cite=
@code=

Test 2


identification division.
program-id. hello.
environment division.
configuration section.
special-names.
decimal-point is comma,
console is crt.
data division.
working-storage section.
01 w-var pic is x(01) value is spaces.
procedure division.
main-paragraph.
*>-> Comment line
display "hello world".
stop run.

Edited 1 time(s). Last edit at 04/11/2017 08:11 by human.

Options: Reply | Quote | Up ^


#4 Re: Question to the board highlighter

Posted by: human | Date: 04/11/2017 08:15 | IP: IP Logged

pspad:
Petr Dvorak isn't available long time already.
I tried to fix CODE in forum myself. Test it.

The CSS part of the fix is correct - we now have all the white spaces that is in the code. But this leads to a problem of multitude new lines as these are now used 1:1 (as they should) and the old additional<br>and<p>inserted there lead to additional line breaks.
There must not be any generation of<br>and<p>inside[code]-tags (the PHP part seems to be missing).

human

Options: Reply | Quote | Up ^


#5 Re: Question to the board highlighter

Posted by: human | Date: 04/24/2017 18:31 | IP: IP Logged

friendly ping

Options: Reply | Quote | Up ^


#6 Re: Question to the board highlighter

Posted by: pspad | Date: 04/24/2017 18:37 | IP: IP Logged

I am sorry, I dont have enough time to do it now

Options: Reply | Quote | Up ^


#7 Re: Question to the board highlighter

Posted by: human | Date: 04/25/2017 16:47 | IP: IP Logged

pspad:
I am sorry, I dont have enough time to do it now

Can you upload the PHP(?)-Source somewhere allowing me to check it and suggest a fix?

Options: Reply | Quote | Up ^






Editor PSPad - freeware editor, © 2001 - 2017 Jan Fiala
Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák