Maniphest T48459

Update Tab Addons to Choose tab name
Closed, ResolvedPATCH

Assigned To
Brendon Murphy (meta-androcto)
Authored By
Brendon Murphy (meta-androcto)
May 18 2016, 10:05 AM
Tags
  • Add-ons (Community)
Subscribers
Brendon Murphy (meta-androcto)
Germano Cavalcante (mano-wii)
Jeffrey Hoover (italic_)

Description

This task is spread out over several addons in release & contrib.

Purpose: To allow users to change which tabs the Addons appear in.

Fixes: It's a very common compliant that tabs get easily overcrowded & misused. This fixes that by allowing users to set up their own tab system or relocate addons to where they need them within the toolshelf.

Usage: Open Addons Preferences, Rename the current Tab name to one you choose or leave as default.

Code:
Using Align Tools in contrib as an example

## Addons Preferences Update Panel
def update_panel(self, context):
    try:
        bpy.utils.unregister_class(AlignUi)
    except:
        pass
    AlignUi.bl_category = context.user_preferences.addons[__name__].preferences.category
    bpy.utils.register_class(AlignUi)   
    
class AddonPreferences(bpy.types.AddonPreferences):
    # this must match the addon name, use '__package__'
    # when defining this in a submodule of a python package.
    bl_idname = __name__

    category = bpy.props.StringProperty(
            name="Category",
            description="Choose a name for the category of the panel",
            default="Tools",
            update=update_panel)

    def draw(self, context):

        layout = self.layout
        row = layout.row()
        col = row.column()
        col.label(text="Category:")
        col.prop(self, "category", text="")

Addons Affected:
Note:`Defaults will not change
Addons Contrib (in Testing Category):
space_view3d_align_tools *Completed
space_view3d_toolshelf_menu *Completed
object_boolean_tools *Completed
oscurart_tools *Completed

Contrib I/O:`
Note:`Whilst Defaults will not change per se, it seems like i/o addons could be changed to a category Import/Export
i/o cacharanth *fix registration bug, no other change
i/o export paper model *no change
i/o mesh cache tools *no change

Addons Affected:
Addons Release (in Community Category):
space_view3d_3d_navigation *requires own Task
ui_layer_manager * Complete

Release I/O:`
io_import_scene_unreal_psa_psk ( still uses Misc Tab, will change to Import/Export ) *Complete
io_export_unreal_psk_psa ( still uses Misc Tab, will change to Import/Export ) *Complete
io_online_sketchfab *no change
light_field_tools ( still uses Misc Tab, will change to Tools Tab ) *Complete

Summary: This set's a positive trend in addons ui management, With the exception of the i/o tools I will be updating all the listed addons to include this function. Also misc category should not be used the three affected addons will have tab change as indicated above.

Thanks.

Related Objects

Mentioned In
T96820: Addon custom categories/tabs are broken (are gone after a session)
rBA4eafe3195c9a: Add Tab Name Change: T48459
rBA27a781104baf: Fix panel category: T48459
rBA2fe2dbdc482c: Add Panel Category: T48459
rBAC11408fe6b0d7: fix last commit, add Multi Panel Support: T48459
rBAC6b389d7279a6: Add Update Panel Name: T48459.
rBACdbd0c9bc774f: Version bump for last commit re: T48459
rBAC8519564c2129: Add Update Panel Name: T48459

Event Timeline

Brendon Murphy (meta-androcto) created this task.May 18 2016, 10:05 AM
Brendon Murphy (meta-androcto) claimed this task.
Brendon Murphy (meta-androcto) raised the priority of this task from to 90.
Brendon Murphy (meta-androcto) updated the task description.
Brendon Murphy (meta-androcto) added a project: Add-ons (Community).
Brendon Murphy (meta-androcto) edited a custom field.
Brendon Murphy (meta-androcto) added a subscriber: Brendon Murphy (meta-androcto).
Brendon Murphy (meta-androcto) lowered the priority of this task from 90 to Normal.May 18 2016, 10:14 AM
Germano Cavalcante (mano-wii) added a subscriber: Germano Cavalcante (mano-wii).May 19 2016, 12:29 AM
Brendon Murphy (meta-androcto) mentioned this in rBAC8519564c2129: Add Update Panel Name: T48459.May 19 2016, 12:08 PM
Brendon Murphy (meta-androcto) mentioned this in rBACdbd0c9bc774f: Version bump for last commit re: T48459.May 19 2016, 12:30 PM
Brendon Murphy (meta-androcto) mentioned this in rBAC6b389d7279a6: Add Update Panel Name: T48459..May 19 2016, 1:01 PM
Brendon Murphy (meta-androcto) mentioned this in rBAC11408fe6b0d7: fix last commit, add Multi Panel Support: T48459.May 19 2016, 1:22 PM
Brendon Murphy (meta-androcto) updated the task description.May 19 2016, 2:09 PM

Update status:
Addons Contrib (in Testing Category):
space_view3d_align_tools *Completed
space_view3d_toolshelf_menu *Completed
object_boolean_tools *Completed
oscurart_tools *Completed

Jeffrey Hoover (italic_) added a subscriber: Jeffrey Hoover (italic_).May 20 2016, 1:15 AM
Brendon Murphy (meta-androcto) updated the task description.May 20 2016, 11:40 AM
Brendon Murphy (meta-androcto) mentioned this in rBA2fe2dbdc482c: Add Panel Category: T48459.May 20 2016, 11:51 AM
Brendon Murphy (meta-androcto) mentioned this in rBA27a781104baf: Fix panel category: T48459.
Brendon Murphy (meta-androcto) mentioned this in rBA4eafe3195c9a: Add Tab Name Change: T48459.May 20 2016, 11:56 AM
Brendon Murphy (meta-androcto) updated the task description.May 20 2016, 11:58 AM
Brendon Murphy (meta-androcto) changed the task status from Unknown Status to Resolved.May 20 2016, 12:10 PM

Update Status: Complete.
I decided to pass over some addons in the list as they are quite specific & the Authors should handle the naming of the addons Tab Category's themselves.
Whilst this goes only a small way to address the issues with Tab name misuse, already other addons devs are adopting the system in their own.
Hopefully this will continue to be used within & outside Blender to allow users more freedom to change Tab names & move Panels to suit themselves & clean up their ui.
Thanks.
Closing as Resolved.