Android Question BBCodeView - Punctuation marks on the end of the line

js486dog

Active Member
Licensed User
BBCodeView - [Alignment=justify]
also
BBCodeView - [Alignment=left]

Punctuation marks ( . , ! ? : ; ) should be on the end of the line when there is not space between the word and punctuation marks (my son, daughter).

BBCodeView loads text sometimes with punctuation marks on the beginning of the line. As is on the pic1.png.

Please is it possible to load text with punctuation marks on the end of the line? As is on the pic2.png?
 

Attachments

Last edited:

js486dog

Active Member
Licensed User
Try it with v1.64. The comma will not be treated as a separate token.
Thank you very much Erel.
It works fine:
B4X:
TView.TextEngine.WordBoundariesThatCanConnectToPrevWord=".,':?!"
But I do not know how to do it also with Double Quotation Marks:

"Some long text here with the dot in the end into Double Quotation Marks."
Please look also picture.
 

Attachments

Erel

Administrator
Staff member
Licensed User
You can add quotes to this string with:
B4X:
TView.TextEngine.WordBoundariesThatCanConnectToPrevWord=$".,':?!""$
However it will probably won't work as you expect it because there are two adjacent separators here. You can actually try to remove "." from the boundaries characters:
B4X:
TView.TextEngine.WordBoundaries = "&*+-/<>=\' :{}" & TAB & CRLF & Chr(13)
It will be then treated like any other letter.
 

js486dog

Active Member
Licensed User
You can add quotes to this string with:
B4X:
TView.TextEngine.WordBoundariesThatCanConnectToPrevWord=$".,':?!""$
However it will probably won't work as you expect it because there are two adjacent separators here. You can actually try to remove "." from the boundaries characters:
B4X:
TView.TextEngine.WordBoundaries = "&*+-/<>=\' :{}" & TAB & CRLF & Chr(13)
It will be then treated like any other letter.
Thank you very much Erel this works fine:
B4X:
TView.TextEngine.WordBoundaries = "&*+-/<>=\' :{}" & TAB & CRLF & Chr(13)
 
Top