https://bugs.documentfoundation.org/show_bug.cgi?id=163512
--- Comment #9 from Buovjaga <[email protected]> --- (In reply to FredrikL from comment #8) > I found a fix for this bug but the fix has not been reported properly yet as > this is the first time ever looking at the source code and it did not seem > like the easiest thing to report the proper way. > > I took help by Claude to get a fix for this bug. > > There is only one line of code that needs to be changed. > > Replace line 917 in source file /libreoffice/sc/source/core/data/postit.cxx > > pCaption->SetMergedItem( makeSdrTextAutoGrowWidthItem( true ) ); > > with > > pCaption->SetMergedItem( makeSdrTextAutoGrowWidthItem( > officecfg::Office::Calc::Content::Display::NoteAuthor::get() ) ); > > or if you want a comment to this change it could be changed into this > instead: > > // tdf#163512: Only auto-grow width when author display is enabled. > // When author is hidden the caption should use the stored note width. > pCaption->SetMergedItem( makeSdrTextAutoGrowWidthItem( > officecfg::Office::Calc::Content::Display::NoteAuthor::get() ) ); > > Do I have to report the fix the way suggested in the link below or is > someone reading this that already knows how to easily send in this fix the > proper way? > https://wiki.documentfoundation.org/Development/gerrit/SubmitPatch You don't mention, if you built and tested the change. As you know, LLMs are guessing engines and after a couple of trillions of USD investment, they are making quite good guesses. But we should be doing changes based on our own understanding and testing and our AI policy reflects that: https://wiki.documentfoundation.org/Development/AI_policy I built the change and it doesn't have the effect you hoped. For whatever reason, it looks like the NoteAuthor boolean isn't initialised when we open LibreOffice and the comment is not shown upon hover. If I go to the options and change the display option, hover works again. When the display is false, the comment box is now more narrow than before the code change, maybe half of what is used to be. I see the display also seems to work somehow erratically, so it might go into a state where it refuses to show the comment upon hover no matter how I change the option. This is all a bit strange as in line 901 there is already a condition that relies on the NoteAuthor boolean for printing the author data and it always worked fine. Looks like debugging needs to be done. I recommend to stop using Claude for this and to rely on your own wits based on what you actually see. -- You are receiving this mail because: You are the assignee for the bug.
