Too long icon lists in the Python API documentation #84320

Closed
opened 2021-01-02 11:10:57 +01:00 by Roman Markov · 7 comments

https://docs.blender.org/api/current/bpy.types.UILayout.html

The icon lists take too much space on this page, making it difficult to navigate.

They repeat 12 times and take:

  • 81% of the characters
  • 66% of the words
  • 54% of the lines

I have to use this javascript before I can look something up. The Icon Viewer is the way to look for icons.

var paragraphs = document.getElementsByTagName('p');

for (let paragraph of paragraphs) {
var result = paragraph.innerHTML.search("TRACKING_CLEAR_FORWARDS'");
if (result != -1){
paragraph.remove();
}
}

https://docs.blender.org/api/current/bpy.types.UILayout.html The icon lists take too much space on this page, making it difficult to navigate. They repeat 12 times and take: - 81% of the characters - 66% of the words - 54% of the lines I have to use this javascript before I can look something up. The [Icon Viewer ](https://docs.blender.org/manual/en/latest/addons/development/icon_viewer.html) is the way to look for icons. ```lang=javascript var paragraphs = document.getElementsByTagName('p'); ``` for (let paragraph of paragraphs) { var result = paragraph.innerHTML.search("TRACKING_CLEAR_FORWARDS'"); if (result != -1){ paragraph.remove(); } } ```
Author

Added subscriber: @unwave

Added subscriber: @unwave

Added subscriber: @rjg

Added subscriber: @rjg

@unwave The API docs are meant to document possible parameter choices. While the way it currently displays the information may not be ideal, it certainly shouldn't be removed.

@unwave The API docs are meant to document possible parameter choices. While the way it currently displays the information may not be ideal, it certainly shouldn't be removed.

Closed as duplicate of #76453

Closed as duplicate of #76453
Author

I would suggest making them collapsible if it is a principle, as a limitation of auto-generated documentation. But for me, it is better to write that the parameter takes an icon sting id and add a link to a page with all the icons with the images of them, like this . Those name lists are practically useless and lower readability of other possible parameter choices. I think icons should be an exception.

Also, the documentation lacks a widget gallery.
Like these:

https://doc.qt.io/qt-5/gallery.html

Even a dirty one will benefit it a lot. A GUI documentation needs imagery, thus demands to be built differently than just a text.

I would suggest making them collapsible if it is a principle, as a limitation of auto-generated documentation. But for me, it is better to write that the parameter takes an icon sting id and add a link to a page with all the icons with the images of them, like [this ](https://wxpython.org/Phoenix/docs/html/stock_items.html). Those name lists are practically useless and lower readability of other possible parameter choices. I think icons should be an exception. Also, the documentation lacks a widget gallery. Like these: - https://docs.wxpython.org/gallery.html - https://python-gtk-3-tutorial.readthedocs.io/en/latest/gallery.html # https://doc.qt.io/qt-5/gallery.html Even a dirty one will benefit it a lot. A GUI documentation needs imagery, thus demands to be built differently than just a text.

Added subscriber: @Blendify

Added subscriber: @Blendify

I agree with your suggestions, but that decision has to be made by @Blendify

I agree with your suggestions, but that decision has to be made by @Blendify
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-manual#84320
No description provided.