From f1ab1132ea6f8be5cf41e9bd77d5f582d5e25ee0 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Wed, 4 Aug 2021 16:38:36 +0200 Subject: QXpmHandler: clean up write_xpm_image: make w,h const MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ... and use one variable definition per line. Change-Id: Ie8e6d6fb9e570cf715ab0b39c78d677f1e5a19a7 Reviewed-by: MÃ¥rten Nordheim --- src/gui/image/qxpmhandler.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/gui/image/qxpmhandler.cpp b/src/gui/image/qxpmhandler.cpp index ecfce93ee5..d00c887b71 100644 --- a/src/gui/image/qxpmhandler.cpp +++ b/src/gui/image/qxpmhandler.cpp @@ -1118,7 +1118,9 @@ static bool write_xpm_image(const QImage &sourceImage, QIODevice *device, const QMap colorMap; - int w = image.width(), h = image.height(), ncolors = 0; + const int w = image.width(); + const int h = image.height(); + int ncolors = 0; int x, y; // build color table -- cgit v1.2.3