[GSoC] Comments in Sidebar Deck: Weekly Update

Mohit Marathe mohitmarathe at proton.me
Wed Aug 21 05:19:15 UTC 2024


Hello everyone,

Last week, I fixed some bugs, notably the one where the ui was not 
getting updated after I delete a comment. This bug was introduced 
in the commit where I added context menu for the comment widget. 
Turns out `weld::Container` is not compatible with 
`connect_mouse_press` signal, it started giving "GTK CRITICAL" 
error. So I added the signal to its child which is a `weld::Expander` 
and it works fine now.

There is still this another bug where the context menu is not 
popping up at the place where the mouse was clicked. I believe its 
because, in the `Rectangle` which we pass in the `popup_at_rect` 
method, the co-ordinates should be relative to the parent widget, 
but the `MouseEvent::GetPosPixel` gives the co-ordinates relative to 
the screen (not sure though). Here is the link to the commit: https://gerrit.libreoffice.org/c/core/+/170996/5

I am working on another thing where I'm creating a widget which is 
circle in shape, contains an OUString and has a 
colour(customisable). So I looked at other examples where a custom 
widget was made using `CustomWidgetController`, it usually 
contains some methods like `Paint`, `SetDrawingArea` and so on. I 
followed those implementation as example, but the widget is not 
showing in the ui. Turns out, `Paint` method is not being called. 
There is one signal called `connect_draw`, which should be 
responsible for calling `Paint`, so I used that signal explicitly, but it 
didn't work. Here is a link to the commit: https://gerrit.libreoffice.org/c/core/+/172032/5

Thanks,
Mohit


More information about the LibreOffice mailing list