-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Alignment in restricted mode works not correctly. #53
Comments
I'm not sure I'm understanding this issue. Everything seems to be working exactly as designed, and replacing the angle brackets with their html-encoded counterparts does not result in correct output. Can you describe the problem in another manner? Is there some textile markup you're using which exposes this issue? |
I apologize for the bad description of the problem - was the end of the day. If we turn to the examples and description of the documentation Textile, and then using your module, try to align any tag left-aligned, right-aligned, or justified. The module starts to work not correctly. input:p<. Left aligned paragraph. p>. Right aligned paragraph. p=. Centered paragraph. p<>. This is a very long, almost never ending, sentence with the sole purpose to demonstrate how a justified paragraph would look like if the sentence wraps around several lines. output:p<. Left aligned paragraph. p>. Right aligned paragraph. Centered paragraph.(worked only align:center) p<>. This is a very long, almost never ending, sentence with the sole purpose to demonstrate how a justified paragraph would look like if the sentence wraps around several lines. The problem I explained in a previous post. How valid this result? When restricted=False everything works perfectly. |
Okay, now that you mentioned it's only in restricted mode, that changes things a little bit. And unfortunately, it looks like this is an upstream issue with php-textile. When I tried to run those txstyle examples through php-textile in restricted mode, it raises fatal errors. I'll bring this up as an issue with them, we'll discuss what the proper output should be and work from there. |
In tests for checking aligment you use symbols '<' and '>'
result = t.image('!</imgs/myphoto.jpg!')
But in fact, these symbols was parsed in html special chars. Their looks like '<' and '>' . And therefore working only
Simple way in pattern of reg exp function
replace by
and further
alignments = {'<': 'left', '=': 'center', '>': 'right'}
replace by
alignments = {'\<': 'left', '=': 'center', '\>': 'right'}
EDIT 2017-08-29 17:04 by @sebix: markup
The text was updated successfully, but these errors were encountered: