Python Forum
CKEditor / Rin Editor
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
CKEditor / Rin Editor
#61
I just got nailed with an indentation error that was worse than the original.
I used ctrl-shift-V to paste code, and didn't notice the indentation was stripped off entirely
until pointed out by a user. I've fixed it, so you'll have to review my edits to see what happened.

post was: https://python-forum.io/Thread-Writing-v...-text-file
Reply
#62
if you paste code in code/python tags in the default source mode, then switch it to WYSIWIYG mode, you lose indentation. But not vice-versa. Once you lose the indentation, its gone, it doesnt come back when you switch back to Source mode again. I would avoid WYSIWIYG mode most of the time as it causes a lot of problems. At least thats what ive concluded after playing around with it.
def test():
pass
This is definitely a fluke. Im just not sure if new users are actually doing this to cause a loss of indentation? But if this is the cause the only fix is to get rid of WYSIWYG mode by removing the source button and not allow altering between the two modes.
Recommended Tutorials:
Reply
#63
I don't understand why anyone would push source code button before post code?
Do the misunderstand and think is code tag.
I had to struggle to find this fluke.

We need as source mode button maybe not Quick Reply.
If it only in Preview Post then most have post code and then is indentation intact.

Will see how it's goes,i think it strange if this will happen often.
Reply
#64
(Jul-29-2017, 12:39 AM)snippsat Wrote: Do they misunderstand and think is code tag.
They might. They might think source for python source code. Maybe rename it to mode or something?
Recommended Tutorials:
Reply
#65
Raw text? Post source? Unformatted text? Show markup?
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
Reply
#66
Yes can think of something other than Source,wish can be mistaken to think that it's for code tag in post.
Something with text as @ichabod801 suggests, Raw text is maybe easiest to understand and not mix up with code tag.
Reply
#67
I found the location of where the word "Source" is located. It is hardcoded into the javascript file and not a config file for easy changing. If i change to anything other than the word "source", then the symbol and all text inside the button is empty.

EDIT:
ah i figured it out. The word Source is an image. The Source button text needs to be an image and the name javascript calls the image with the extension.

Attached Files

Thumbnail(s)
       
Recommended Tutorials:
Reply
#68
Quote:I don't understand why anyone would push source code button before post code?
It was the way I learned to program throughout the 1970's and most of the 80's.
Whenever I encounter a problem with a new editor, I tend to go back to basics until
things settle down, and type in bbcode manually. I am comfortable there, because it's
familiar territory.
That's why I do it, perhaps not a good reason, but it's mine.
Reply
#69
Speaking of witch (source editor) where did it go?
My last post: https://python-forum.io/Thread-Pyfirmata-and-Teensy-3-6 has italic tag which I can't get rid of!
I didn't put it there. This is painful.
Reply
#70
im dicking with it right now. Its currently the empty button with no image. I cant seem to get an image to work at all in this button.
Recommended Tutorials:
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020