0. doxy-config file (most of the times names
:INTERNAL_DOCS = NO
1. Doxygen-blocks for classes should be wrapped with
/// @cond INTERNAL
/// @ingroup whateverGRP
2. Maybe use the keyword ‘internal’ for its real purpose 😉
Additional note: only use
for newlines in Doxygen in C#. Else prepare for:
Severity Code Description Project File Line Suppression State
Warning CS1570 XML comment has badly formed XML -- 'Expected an end tag for element 'myTag'.'"
Heob is an OSS project, short for ‘heap observer’.
How to configure and use?
0. The official documentation from Qt/QtCreator is – like always :’D – a bit sparse: https://doc.qt.io/qtcreator/creator-heob.html
1. Get it from: https://github.com/ssbssa/heob/releases (I’ll use here release 3.1 from July 2019) and extract to the directory of your choice. This directory has to be set later as configuration path.
If you use gcc/mingw, then make sure you’ve dwarf-stack enabled. Since I’m just using the MSVC, not much had to be done.
2. Inside QtCreator (I am using right now 4.12 from the Maintenance Installer) go to “Analyze > Heob” and configure it like this:
The floppydisk-icon can be saved to store ONE configuration.
I leave most of the time the tracing to simple, else time-critical processes can fail. The output-files should be named if you do several runs, which you want to compare or post-process. Most of the time it makes sense to start disabled, because else heob tracks already all the losses at start and this will delay the start.
3. As example, I’ve set Cullendula as UUT (unit under test).
Since heob was started disabled, the leak recording is off: Activate it by pressing ‘n’. If you resize the terminal, the last line can become invisible due to some glitch. So better leave the size of the window untouched!
4. Do your favorite workflow in the UUT. Then close/quit the UUT.
5. Depending on how much allocations were done, heob takes more (up to ten minutes!) or less time (seconds in the case of Cullendula) to evaluate the leaks.
The results are sorted in descending order. Expand the entries to check the stack-trace of the cause.
Some can be triggered by leaks in the underlying libraries (Qt .. I am lookin at you: https://bugreports.qt.io/browse/QTBUG-59621), some by your own buggy implementation.
Hint: the generated xml-report can be later loaded again in the results-tab. Or specify “-o leaks20200617.html” for an optically more pleasing result.
People always talk always about shopping & happiness. Now I can understand :’) Just booked for the upcoming weeks for my education “Workshop: Deep Learning für Natural Language Processing (NLP)” && “iSAQB Certified Professional for Software Architecture – Foundation Level (CPSA-FL)” <3 #neverstoplearning
nota bene: and HSK1 for Mandarin will be tackled as well!
A note before the actual post: a week ago, while proofreading I’ve noticed that some of the following statements, which are meant truly neutral, could and would leave a stale aftertaste. That’s definitely not the intention; it’s more a snapshot of the current state (like for a chronicle). On the other hand: if I would censor it more, I can trash as well the whole post. Because ten thousands of texts were already written about the curent state of human society and the impact of Covid-19.
So, read it with a pinch of salt: we are lucky to be healthy and that we don’t suffer from more harsh conditions.
More than two months ago Sars-CoV-2 -induced infections scaled up in Germany and hit us without much preparation. Us includes me, my family, my workplace, society at all.
(I don’t care about output from the taskmanager or whatever logs. I need a processable duration without much tinkering.)
Copyright (C) Microsoft Corporation. Alle Rechte vorbehalten.
PS C:\WINDOWS\system32> (get-date) - (gcim Win32_OperatingSystem).LastBootUpTime
Days : 15
Hours : 3
Minutes : 25
Seconds : 57
Milliseconds : 956
Ticks : 13083579564019
TotalDays : 15,1430319027998
TotalHours : 363,432765667194
TotalMinutes : 21805,9659400317
TotalSeconds : 1308357,9564019
TotalMilliseconds : 1308357956,4019
It’s quite funny. 2012 I’ve used the first time macOS (or how it was called OSX) in version 10.6.8. Now Apple has reached 10.15 and there is still no proper, simple, menu-guided way to enable an file-explorer for productive use.
How to show the current path in the title of the finder:
(bash and then enter those two lines for configuration and restarting the Finder)
defaults write com.apple.finder _FXShowPosixPathInTitle -bool true
How to go to a known path:
Ctrl+Shift+G -> then enter the path.
Git is my VCS-system of choice and github most of the time the place for my publicly shared repositories.
Over the years some clutter piled up there:
- unfinished business; projects which were started (with best intentions) and never finished
- forked repositories, which I don’t need anymore (not sure if I will remove also those were I contributed, because then the evidence is more or less gone, or?)
- code I am a bit ashamed right now :’) (if you have no projects were you laugh heartily about how naively you implemented them at that time, then you made no progress)
Therefore I started to check them to see if it makes sense to keep or delete them. Right now I am down to 39 and the delete-button is still hot 😉
At first this looked like a bug, but upon reading carefully the documentation and crawling the internet, I’ve noticed that this is
a) wanted behavior and b) I am not the first one stumbling over this issue.
So just override in the header the method for processing the QHideEvent:
// Closing a QDialog via key 'ESC' does NOT result in a close-event.
// Therefore we capture the QHideEvent <3
void hideEvent(QHideEvent* eventHorizon) override;
And reimplement the base-class-call with the emission of a custom signal (or triggering custom functionality) for futher processing. Like:
// emit signalDialogClosed();
Another way is to connect the QDialog’s finished-signal to your signal via DirectConnection. Less code than overriding.