Summary: | Build plug-in should report outcome of compilation more precisely | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | Oliver Sander <oliver.sander> |
Component: | general | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | ||
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: |
Patch for the kate build plugin that improves the content of some message boxes, as requested in 242503
Revised patch for wishlist item 242503 |
Description
Oliver Sander
2010-06-22 18:04:47 UTC
Created attachment 52802 [details]
Patch for the kate build plugin that improves the content of some message boxes, as requested in 242503
I wrote a patch that implements the requested behavior. The build plugin now counts the number of errors and warnings. The message window mentions errors and warnings only if there have actually been errors and warnings, respectively. If there have been, reasonably precise numbers are given. Please review the patch and apply it if it meets your standards. Thanks. Hey Oliver, I'd personally just use "if (m_num_errors_found)" instead of checking for > 0 all the time. Also camel cased variable names are preferred: m_numErrors and m_numWarnings is imo better. And the part with the passive popup is not looking good to me. It should always use i18np. And it would be simpler if you do it like this: if (m_numErrors || m_numWarnings) { QStringList msgs; if (m_numErrors) { msgs << i18np("Found one error.", "Found %1 errors.", m_numErrors); } if (m_numWarnings) { msg << i18np("Found one warning.", "Found %1 warnings.", m_numErrors); } KPassivePopup::message(i18n("Make Results"), msgs.join("\n"), m_toolView); } Otherwise good job :) If you fix the above stuff I'll happilly merge the patch. Bye Hi Milian! Thanks for the review. I attach a revised patch, which includes all of your suggestions. -- Oliver Created attachment 52838 [details]
Revised patch for wishlist item 242503
committed to git, thanks SVN commit 1191596 by cullmann: mwolff: Show amount of compile errors and warnings in popup of build plugin. Thanks for the patch to Oliver Sander. BUG: 242503 M +21 -13 plugin_katebuild.cpp M +2 -1 plugin_katebuild.h WebSVN link: http://websvn.kde.org/?view=rev&revision=1191596 |