I noticed you cannot do tab to indent while
typing out a script and wondered if this is a possible addable functionality to typing out devforum feedback posts.
I know that I can just write code out on Studio but sometimes I may not be able to access Studio or want to necessarily have to go through the minor hassle of going somewhere else to write some code.
I neither want to press space 4 times per line to copy a tab.
I would use this to write short example code faster and without the need of going out of my browser to do this in the help & feedback category.
This is just a minor feedback request but I just wanted to share my opinion.
We should add it here instead. Adding four spaces instead of tabs is a horrible experience, and when the OP copies over the code, it has inconsistent indentationsbecause they used tabs where I used spaces. The reverse exists too: I copy code from the OP, edit it a bit, but now I have to remove each tab and replace it with 4 spaces.
Though I do admit that the tab key in its current state is useful. Instead of hovering over the reply button after finishing a post I can just press tab and then enter.
Maybe the indentation should only be enforced when a user is within a code block:
I am not sure what Discourse is but it sounds like that’s what the dev forum uses. Wouldn’t it be too specific of a request to ask them specifically?
Just have a text editor or studio baseplate open in the background while you browse the forum. Write the code there and copy and paste it into the reply you’re making. Discourse was not designed to be a code editor anyway.
In the case that you’re making a small change, I think adding 4 spaces wouldn’t be too much work, but if you’re writing a whole script or segment of code, I think it’d be better to use studio or a text editor.
It isn’t to be used as a code editor but the forum is effectively made for development so scripting is a part of it and I believe it would work for the dev forum specifically instead of Discourse.
I agree with that. Sure you can use alternatives to make it so you don’t even need to code on devforums and just copy/paste but isn’t that more of a excuse than a solution? Can’t deny it’ll probably make our lives easier if we can code the general understanding of code we know versus going into studio to use it as a text editor basis for indenting.
This should be requested at meta.discourse.org since the editor is made by Discourse, and a ton of Discourse fora are aimed at programmers. Roblox won’t put engineering time into this, it’s not feasible to maintain a change to the editor just to support this when it’s such generic functionality.
From engineering perspective, it’s a silly amount of effort to fork the editor over an addition like this unfortunately. Roblox would need to make sure that their modification doesn’t break every time Discourse updates (which is very often, once every 1-2 weeks).
The feature doesn’t seem useful enough to warrant this. In normal usage people would copy-paste code into the editor, not code inside it.
You’re right so I’ll give up on the idea since it possibly breaking frequently isn’t a good idea.
However, in normal usage, I do not think people copy-paste code into the editor all the time normally, there are questions that involve examples and thus repliers have to make example code themselves. We either accept our fate of using the spacebar for indenting or just take the extra time to go into some editor to type the code.
I think I agree with Jeff on this one. I use TabEnter to submit posts all the time, and there have been cases when I am inside a code block and want to do the same thing. I’d be seriously PO’d if I went to submit a post and instead inserted a literal tab character.