Dear PlantUML Team,
I would like to request a new feature that allows users to add a dedicated diagram description block at the top of a diagram, aligned to the left, without a border. This would serve as a clean, unobtrusive summary, improving readability and enhancing diagram documentation.
Why is this needed?
Currently, existing elements do not fully address this requirement:
- Headers are unsuitable when the title is displayed below, causing layout inconsistencies.
- Legends can be placed below the title, but they do not support multiple legends, making structured annotations challenging.
- Adding a new dedicated description block would provide a clear, well-positioned summary below the title while maintaining proper alignment and readability.
Suggested Implementation:
- The description block should be positioned below the title.
- It should align left, providing a structured introductory section.
- No visible border, ensuring it blends naturally with the diagram.
- Should not interfere with other diagram elements, maintaining logical spacing and order.
Previous Attempts to Solve the Issue:
I have already explored possible solutions and shared suggestions in the following discussions:
https://forum.plantuml.net/20086/add-a-borderless-text-box-for-diagram-description
https://forum.plantuml.net/20085/how-to-add-a-diagram-description-at-the-top-without-a-border
However, these approaches do not fully satisfy the desired layout, as they either impact placement or introduce unwanted formatting constraints.
Conclusion:
Adding a dedicated description block would significantly improve diagram documentation by providing a structured, non-intrusive way to convey important context. This enhancement would be highly beneficial for users who require clear explanations without affecting existing diagram elements.
I appreciate your time and consideration, and I hope this feature can be incorporated into a future update. Looking forward to your thoughts on this!
Best regards,
Omar
Example applying suggested approach, which is not suitable:
@startuml
skinparam maxMessageSize 40
title
<font color=red>Notebook Selection using wxQueueEvent</font>
<font color=red>AddNoteBook_OnClickTreControl_Event</font>
end title
<style>
header {
HorizontalAlignment left
FontSize 26
FontColor black
Margin 30
}
</style>
left header
This diagram illustrates the use of wxQueueEvent for creating a new notebook when the user double-clicks an item in the tree control.
It emphasizes asynchronous communication between the Tree Control and Notebook using event handling mechanisms.
endheader
actor Actor
participant wxApp
participant mTreeCtrlPtr as TreeCtrl_ElmFiles
participant mNotebookPtr as AuiNotebook
Actor -> wxApp : Tab Click/Selection
wxApp -> AuiNotebook : EVT_AUINOTEBOOK_PAGE_CHANGED
AuiNotebook -> AuiNotebook: OnPageChanged(event)
activate AuiNotebook
AuiNotebook -> AuiNotebook: selectedIndex = event->GetSelection()
opt selectedIndex != -1
AuiNotebook -> AuiNotebook: selectedPage = GetPage(selectedIndex)
opt selectedPage != nullptr
AuiNotebook -> AuiNotebook: customEventPtr = new EvNotebook2TreeControl(EVT_CUSTOM_NOTEBOOK_CHANGED, GetId())
opt customEventPtr != nullptr
AuiNotebook -> AuiNotebook: customEventPtr.SetTreeItemId(selectedPage.GetTreeItemId())
AuiNotebook -[#blue]> TreeCtrl_ElmFiles: <font color=blue> wxQueueEvent(mTreeCtrlPtr, customEventPtr)
deactivate AuiNotebook
activate TreeCtrl_ElmFiles
note over AuiNotebook, TreeCtrl_ElmFiles: QueueEvent posts the event\nasynchronously to the tree control
TreeCtrl_ElmFiles -> TreeCtrl_ElmFiles: OnCustomEvent_NotebookChanged(event)
note right of TreeCtrl_ElmFiles: Retrieve tree item ID from the event
TreeCtrl_ElmFiles -> TreeCtrl_ElmFiles: itemId = event->GetTreeItemId()
opt itemId.IsOk() == true
TreeCtrl_ElmFiles -> TreeCtrl_ElmFiles: SelectItem(itemId, true)
end
deactivate TreeCtrl_ElmFiles
end
end
end
@enduml
http://www.plantuml.com/plantuml/png/bLHHRzis47xdhxXXBpOGErqtx268ZRgkcnf3ucnnzx8D0YsT9S8KAP0d9-cm_xwZQBLIPHJDWmr9_Exxlljuv1jFqb5TQk4FobJIoH9A-NIBtiiS7zGdX5zU2K6AD8hhlJK4gTNMpHncypjBkBFs00-eCILb3THUcHmUdtwliSRL4GrTNuQg-Q1uaMMX_YtN9nkpr2ezR1qk6UIiJdgbQ3A83eIuzlIiSIuAb1aw-5Tyi4vzOfZK2wroKt8TQDoJUCyVcmPU_zeyBuCqxBHC3-9MkbmP-FcL-4zSNvueHIY3I2osXVAGAPc7H9JMjISd2JrGWTmbWjttseGzawSE9OK091Xy1DFcyrYWQGiTPBRUQPoaeMKFqe0YP8s888S8QKnX2c9DW6LLIC-DCDO_cxHmrjZQCwWiQwDIsGI_Gth4ayesS9oIPFuCseqwRGysXWjUqU6rn9I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