Author Topic: new idea: copy the code snippet in the editor, and add filename and lines tags  (Read 11610 times)

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
This is just an idea, when we post some code snippet, we have to write something like below:

Code
filename: xxx/xxx/xxx.cpp, from line xxx to line xxx:

[begin tag]
code
code
code
[end tag]


I think the begin tag and end tag should at least support the BBcode and Markdown syntax. I'm not sure currently there is any plugin implement this. What do you think?

Thanks.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2808
I tried posting with markdown in the CB forum.
It doesn't work for me.

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 6034
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
I tried posting with markdown in the CB forum.
It doesn't work for me.

Sure, our forum only support BBcode. But other site such as Stackoverflow or github support markdown.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.