5

This question shows how to document a custom function. However, I'd like to document my function in the same way the rest of the functions are.

enter image description here

So far, I just can manage to create the highlited part of the documentation but I can't find anywhere how to implement the same format used for the rest of the functions.

Is it possible to accomplish this in a custom function?

4

You can use HTML and/or CSS in the function's DocString.

viewing custom doc format

creating fancy documentation

  • Great!! This is exactly what I was looking for. Do you know where can I find inside the QGIS files some of the preset functions so I can copy the same template? – Albert Jun 7 '17 at 15:25
  • 1
    @Albert I couldn't find them.. maybe they are in the source code, but there is no guarantee they are using the same mechanism/language – JGH Jun 7 '17 at 15:32
  • Oh, I couldn't find them either. Well, at least now I know how to do it manually. Thank you! – Albert Jun 7 '17 at 15:36
  • 2
    the scale_exp function appears to be documented using json, as @JGH suggests it's not necessarily a python function. – Steven Kay Jun 7 '17 at 20:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.