Skip to content

Conversation

@linev
Copy link
Member

@linev linev commented Nov 27, 2025

After invoking:

   addDrawFunc({
      name: '*',
      func: (dom,obj,opt) => console.log('drawing', obj._typename)
   });

Provided function will be invoked every time when some object is drawn
If function returns value - this will be the only action then

Allows catch and redefine drawing of any object in jsroot.
But TTree::Draw will be performed and only produced histogram
drawing will be alternated

Remove setDrawFunc functionality for hierarchy painter while it is not enough for real use cases

Update hpainter.js demo to show that happens

After invoking:
```
   addDrawFunc({
      name: '*',
      func: (dom,obj,opt) => console.log('drawing', obj._typename)
   });
```
Provided function will be invoked every time when some object is drawn
If function returns value - this will be the only action then

Allows catch and redefine drawing of any object in jsroot.
But TTree::Draw will be performed and only produced histogram
drawing will be alternated
@linev linev self-assigned this Nov 27, 2025
@linev linev merged commit 54371f7 into master Nov 27, 2025
24 checks passed
@linev linev deleted the global_draw branch November 27, 2025 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants