r22518 by craig - More nullptr and other conversions

scribus-commit scribus-commit at lists.scribus.net
Wed May 2 22:17:14 UTC 2018


Author: craig
Date: Wed May  2 22:17:14 2018
New Revision: 22518

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=22518
Log:
More nullptr and other conversions

Modified:
    trunk/Scribus/scribus/actionmanager.cpp
    trunk/Scribus/scribus/appmodehelper.cpp
    trunk/Scribus/scribus/canvasgesture_linemove.cpp
    trunk/Scribus/scribus/canvasgesture_rulermove.cpp
    trunk/Scribus/scribus/canvasmode_create.cpp
    trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
    trunk/Scribus/scribus/canvasmode_drawfreehand.cpp
    trunk/Scribus/scribus/canvasmode_edit.cpp
    trunk/Scribus/scribus/canvasmode_edittable.cpp
    trunk/Scribus/scribus/canvasmode_editweldpoint.cpp
    trunk/Scribus/scribus/canvasmode_eyedropper.cpp
    trunk/Scribus/scribus/canvasmode_imageimport.cpp
    trunk/Scribus/scribus/canvasmode_objimport.cpp
    trunk/Scribus/scribus/canvasmode_rotate.cpp
    trunk/Scribus/scribus/colormgmt/scciedata.cpp
    trunk/Scribus/scribus/colormgmt/sccolormgmtengine.cpp
    trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
    trunk/Scribus/scribus/colormgmt/sclcms2colorprofileimpl.cpp
    trunk/Scribus/scribus/colormgmt/sclcms2colortransformimpl.cpp
    trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
    trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.cpp
    trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.h
    trunk/Scribus/scribus/colormgmt/sclcmscolortransformimpl.cpp
    trunk/Scribus/scribus/fonts/ftface.cpp
    trunk/Scribus/scribus/fonts/scface.cpp
    trunk/Scribus/scribus/fonts/sfnt.cpp
    trunk/Scribus/scribus/fpointarray.cpp
    trunk/Scribus/scribus/gtgettext.cpp
    trunk/Scribus/scribus/gtwriter.cpp
    trunk/Scribus/scribus/guidemanagercore.cpp
    trunk/Scribus/scribus/guidemanagercore.h
    trunk/Scribus/scribus/imagedataloaders/scimgdataloader_gmagick.cpp
    trunk/Scribus/scribus/imagedataloaders/scimgdataloader_jpeg.cpp
    trunk/Scribus/scribus/imagedataloaders/scimgdataloader_ps.cpp
    trunk/Scribus/scribus/imagedataloaders/scimgdataloader_tiff.cpp
    trunk/Scribus/scribus/observable.h
    trunk/Scribus/scribus/pageitem_textframe.h
    trunk/Scribus/scribus/pdflib_core.cpp
    trunk/Scribus/scribus/scclocale.cpp
    trunk/Scribus/scribus/scdocoutput.cpp
    trunk/Scribus/scribus/scfonts.cpp
    trunk/Scribus/scribus/sclayer.cpp
    trunk/Scribus/scribus/scraction.cpp
    trunk/Scribus/scribus/scribusdoc.cpp
    trunk/Scribus/scribus/scstreamfilter.cpp
    trunk/Scribus/scribus/scstreamfilter_jpeg.cpp
    trunk/Scribus/scribus/sctextstruct.cpp
    trunk/Scribus/scribus/sctextstruct.h
    trunk/Scribus/scribus/selection.cpp
    trunk/Scribus/scribus/text/itextsource.h
    trunk/Scribus/scribus/text/screenpainter.cpp
    trunk/Scribus/scribus/text/sctext_shared.cpp
    trunk/Scribus/scribus/text/shapedtext.cpp
    trunk/Scribus/scribus/text/shapedtextcache.cpp
    trunk/Scribus/scribus/text/shapedtextfeed.cpp
    trunk/Scribus/scribus/text/shapedtextfeed.h
    trunk/Scribus/scribus/text/storytext.h
    trunk/Scribus/scribus/text/textcontext.cpp
    trunk/Scribus/scribus/text/textlayout.cpp
    trunk/Scribus/scribus/text/textshaper.cpp
    trunk/Scribus/scribus/tocgenerator.cpp
    trunk/Scribus/scribus/ui/sctablewidget.cpp
    trunk/Scribus/scribus/undomanager.h
    trunk/Scribus/scribus/util.h
    trunk/Scribus/scribus/util_color.cpp

Modified: trunk/Scribus/scribus/actionmanager.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/actionmanager.cpp
==============================================================================
--- trunk/Scribus/scribus/actionmanager.cpp	(original)
+++ trunk/Scribus/scribus/actionmanager.cpp	Wed May  2 22:17:14 2018
@@ -1251,7 +1251,7 @@
 
 void ActionManager::connectNewDocActions(ScribusDoc *currDoc)
 {
-	if (currDoc==NULL)
+	if (currDoc==nullptr)
 		return;
 	connect( (*scrActions)["itemLock"], SIGNAL(triggered()), currDoc, SLOT(itemSelection_ToggleLock()) );
 	connect( (*scrActions)["itemLockSize"], SIGNAL(triggered()), currDoc, SLOT(itemSelection_ToggleSizeLock()));
@@ -1313,7 +1313,7 @@
 
 void ActionManager::connectNewViewActions(ScribusView *currView)
 {
-	if (currView==NULL)
+	if (currView==nullptr)
 		return;
 	//qDebug()<<"connectNewViewActions"<<currView->Doc->DocName;
 	connect( (*scrActions)["viewPreviewMode"], SIGNAL(toggled(bool)), currView, SLOT(togglePreview(bool)) );
@@ -1359,7 +1359,7 @@
 		(*scrActions)[*it]->setShortcutContext(Qt::WidgetShortcut);  // in theory, this should be enough, but...
 		(*scrActions)[*it]->saveShortcut();
 #ifdef Q_OS_MAC
-		if ((*scrActions)[*it]->menu() != NULL)
+		if ((*scrActions)[*it]->menu() != nullptr)
 			(*scrActions)[*it]->setEnabled(false);
 #endif		
 	}
@@ -1425,10 +1425,10 @@
 
 void ActionManager::setPDFActions(ScribusView *currView)
 {
-	if (currView==NULL)
+	if (currView==nullptr)
 		return;
 	PageItem* currItem = mainWindow->doc->m_Selection->itemAt(0);
-	if (currItem==NULL)
+	if (currItem==nullptr)
 		return;
 
 	disconnect( (*scrActions)["itemPDFIsBookmark"], 0, 0, 0);
@@ -1821,7 +1821,7 @@
 	//Reset tooltips on actions after the translation process
 	for( QMap<QString, QPointer<ScrAction> >::Iterator it = scrActions->begin(); it!=scrActions->end(); ++it )
 	{
-		if ((*it)!=NULL)
+		if ((*it)!=nullptr)
 			(*it)->setToolTipFromTextAndShortcut();
 	}
 }

Modified: trunk/Scribus/scribus/appmodehelper.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/appmodehelper.cpp
==============================================================================
--- trunk/Scribus/scribus/appmodehelper.cpp	(original)
+++ trunk/Scribus/scribus/appmodehelper.cpp	Wed May  2 22:17:14 2018
@@ -44,13 +44,13 @@
 AppModeHelper::AppModeHelper(QObject *parent) :
     QObject(parent)
 {
-	a_actMgr=NULL;
-	a_scrActions=NULL;
-	a_scrRecentFileActions=NULL;
-	a_scrWindowsActions=NULL;
-	a_scrScrapActions=NULL;
-	a_scrLayersActions=NULL;
-	a_scrRecentPasteActions=NULL;
+	a_actMgr=nullptr;
+	a_scrActions=nullptr;
+	a_scrRecentFileActions=nullptr;
+	a_scrWindowsActions=nullptr;
+	a_scrScrapActions=nullptr;
+	a_scrLayersActions=nullptr;
+	a_scrRecentPasteActions=nullptr;
 }
 
 void AppModeHelper::setup(ActionManager* am,
@@ -85,7 +85,7 @@
 	assert(newMode < submodeFirstSubmode);
 
 	//If no doc and we end here, just reset the tool actions
-	if (doc==NULL)
+	if (doc==nullptr)
 	{
 		resetApplicationMode(scmw, newMode);
 		return;
@@ -130,7 +130,7 @@
 		case modeDrawBezierLine:
 		{
 			//if No nodes were created
-			if (currItem == NULL)
+			if (currItem == nullptr)
 			{
 				setSpecialEditMode(false);
 				break;
@@ -292,15 +292,15 @@
 				}
 				(*a_scrActions)["editPaste"]->setEnabled(false);
 				scmw->charPalette->setEnabled(true, currItem);
-				if (currItem!=NULL && currItem->asTextFrame())
+				if (currItem!=nullptr && currItem->asTextFrame())
 				{
 					enableTextActions(true, currItem->currentCharStyle().font().scName());
 					currItem->asTextFrame()->toggleEditModeActions();
 				}
 				if (ScMimeData::clipboardHasScribusData())
 				{
-					bool textFrameEditMode = ((currItem != NULL) && (currItem->asTextFrame()));
-					(*a_scrActions)["editPaste"]->setEnabled( textFrameEditMode || (currItem == NULL) );
+					bool textFrameEditMode = ((currItem != nullptr) && (currItem->asTextFrame()));
+					(*a_scrActions)["editPaste"]->setEnabled( textFrameEditMode || (currItem == nullptr) );
 				}
 				setTextEditMode(true);
 
@@ -436,14 +436,14 @@
 void AppModeHelper::enableActionsForSelection(ScribusMainWindow* scmw, ScribusDoc* doc)
 {
 	int SelectedType = -1;
-	PageItem *currItem = NULL;
+	PageItem *currItem = nullptr;
 	const int docSelectionCount = doc->m_Selection->count();
 	if (docSelectionCount > 0)
 	{
 		currItem = doc->m_Selection->itemAt(0);
 		SelectedType = currItem->itemType();
 	}
-	assert (docSelectionCount == 0 || currItem != NULL); // help coverity analysis
+	assert (docSelectionCount == 0 || currItem != nullptr); // help coverity analysis
 
 	bool inAnEditMode = doc->inAnEditMode();
 
@@ -1008,7 +1008,7 @@
 
 void AppModeHelper::setActionGroupEnabled(QMap<QString, QPointer<ScrAction> >*ag, bool enabled)
 {
-	if (ag!=NULL)
+	if (ag!=nullptr)
 		for( QMap<QString, QPointer<ScrAction> >::Iterator it = ag->begin(); it!=ag->end(); ++it )
 			(*it)->setEnabled(enabled);
 }

Modified: trunk/Scribus/scribus/canvasgesture_linemove.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasgesture_linemove.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasgesture_linemove.cpp	(original)
+++ trunk/Scribus/scribus/canvasgesture_linemove.cpp	Wed May  2 22:17:14 2018
@@ -43,7 +43,7 @@
 
 void LineMove::prepare(PageItem_Line* line, bool useOriginAsEndpoint)
 {
-	m_haveLineItem = (line != NULL);
+	m_haveLineItem = (line != nullptr);
 	if (!m_haveLineItem)
 		return;
 	m_useOriginAsEndpoint = useOriginAsEndpoint;
@@ -122,7 +122,7 @@
 
 void LineMove::mousePressEvent(QMouseEvent *m)
 {
-	PageItem_Line* line = m_doc->m_Selection->count() == 1 ? m_doc->m_Selection->itemAt(0)->asLine() : NULL;
+	PageItem_Line* line = m_doc->m_Selection->count() == 1 ? m_doc->m_Selection->itemAt(0)->asLine() : nullptr;
 	if (line)
 	{
 		bool hitsOrigin = m_canvas->hitsCanvasPoint(m->globalPos(), line->xyPos());

Modified: trunk/Scribus/scribus/canvasgesture_rulermove.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasgesture_rulermove.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasgesture_rulermove.cpp	(original)
+++ trunk/Scribus/scribus/canvasgesture_rulermove.cpp	Wed May  2 22:17:14 2018
@@ -95,7 +95,7 @@
 
 void RulerGesture::activate(bool fromGesture)
 {
-	m_haveCursor = (qApp->overrideCursor() != NULL);
+	m_haveCursor = (qApp->overrideCursor() != nullptr);
 	if ( (!fromGesture) && qApp->overrideCursor())
 	{
 		m_haveCursor = true;

Modified: trunk/Scribus/scribus/canvasmode_create.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_create.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_create.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_create.cpp	Wed May  2 22:17:14 2018
@@ -71,7 +71,7 @@
 	createObjectSubMode  = 0;
 	modifiers            = 0;
 	m_MouseButtonPressed = false;
-	m_createTransaction  = NULL;
+	m_createTransaction  = nullptr;
 }
 
 
@@ -178,7 +178,7 @@
 inline bool CreateMode::GetItem(PageItem** pi)
 { 
 	*pi = m_doc->m_Selection->itemAt(0); 
-	return (*pi) != NULL; 
+	return (*pi) != nullptr;
 }
 
 // the following code was moved from scribusview.cpp:
@@ -603,7 +603,7 @@
 		{
 			if (!doOneClick(createObjectPos, canvasCurrCoord))
 			{
-				return NULL;
+				return nullptr;
 			}
 		}
 	}
@@ -617,7 +617,7 @@
 			hSize = wSize;
 	}
 
-	PageItem *newObject = NULL, *currItem = NULL;
+	PageItem *newObject = nullptr, *currItem = nullptr;
 	// FIXME for modeDrawLine
 	QRectF createObjectRect(createObjectPos.x(), createObjectPos.y(), wSize, hSize);
 	if (createObjectMode != modeDrawLine)

Modified: trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp	Wed May  2 22:17:14 2018
@@ -59,7 +59,7 @@
 inline bool CalligraphicMode::GetItem(PageItem** pi)
 { 
 	*pi = m_doc->m_Selection->itemAt(0); 
-	return (*pi) != NULL; 
+	return (*pi) != nullptr;
 }
 
 void CalligraphicMode::enterEvent(QEvent *)
@@ -315,7 +315,7 @@
 		m_doc->m_Selection->itemAt(i)->checkChanges(true);
 
 	//Commit drag created items to undo manager.
-	if (m_doc->m_Selection->itemAt(0)!=NULL)
+	if (m_doc->m_Selection->itemAt(0)!=nullptr)
 	{
 		m_doc->itemAddCommit(m_doc->m_Selection->itemAt(0));
 	}

Modified: trunk/Scribus/scribus/canvasmode_drawfreehand.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_drawfreehand.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_drawfreehand.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_drawfreehand.cpp	Wed May  2 22:17:14 2018
@@ -56,7 +56,7 @@
 inline bool FreehandMode::GetItem(PageItem** pi)
 { 
 	*pi = m_doc->m_Selection->itemAt(0); 
-	return (*pi) != NULL; 
+	return (*pi) != nullptr;
 }
 
 void FreehandMode::enterEvent(QEvent *)
@@ -305,7 +305,7 @@
 		m_doc->m_Selection->itemAt(i)->checkChanges(true);
 
 	//Commit drag created items to undo manager.
-	if (m_doc->m_Selection->itemAt(0)!=NULL)
+	if (m_doc->m_Selection->itemAt(0)!=nullptr)
 	{
 		m_doc->itemAddCommit(m_doc->m_Selection->itemAt(0));
 	}

Modified: trunk/Scribus/scribus/canvasmode_edit.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_edit.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_edit.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_edit.cpp	Wed May  2 22:17:14 2018
@@ -80,7 +80,7 @@
 inline bool CanvasMode_Edit::GetItem(PageItem** pi)
 { 
 	*pi = m_doc->m_Selection->itemAt(0); 
-	return (*pi) != NULL; 
+	return (*pi) != nullptr;
 }
 
 
@@ -936,7 +936,7 @@
 	for (int i = 0; i < m_doc->m_Selection->count(); ++i)
 		m_doc->m_Selection->itemAt(i)->checkChanges(true);
 	//Commit drag created items to undo manager.
-	if (m_doc->m_Selection->itemAt(0)!=NULL)
+	if (m_doc->m_Selection->itemAt(0)!=nullptr)
 	{
 		m_doc->itemAddCommit(m_doc->m_Selection->itemAt(0));
 	}
@@ -1026,7 +1026,7 @@
 		m_view->setRulerPos(m_view->contentsX(), m_view->contentsY());
 	}
 	
-	currItem = NULL;
+	currItem = nullptr;
 	if ((m->modifiers() & SELECT_BENEATH) != 0)
 	{
 		for (int i=0; i < m_doc->m_Selection->count(); ++i)
@@ -1094,12 +1094,12 @@
 
 void CanvasMode_Edit::createContextMenu(PageItem* currItem, double mx, double my)
 {
-	ContextMenu* cmen=NULL;
+	ContextMenu* cmen=nullptr;
 	m_view->setCursor(QCursor(Qt::ArrowCursor));
 	m_view->setObjectUndoMode();
 	Mxp = mx;
 	Myp = my;
-	if(currItem!=NULL)
+	if(currItem!=nullptr)
 		cmen = new ContextMenu(*(m_doc->m_Selection), m_ScMW, m_doc);
 	else
 		cmen = new ContextMenu(m_ScMW, m_doc, mx, my);

Modified: trunk/Scribus/scribus/canvasmode_edittable.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_edittable.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_edittable.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_edittable.cpp	Wed May  2 22:17:14 2018
@@ -409,10 +409,10 @@
 
 void CanvasMode_EditTable::createContextMenu(PageItem *currItem, double mx, double my)
 {
-	ContextMenu* cmen=NULL;
+	ContextMenu* cmen=nullptr;
 	m_view->setCursor(QCursor(Qt::ArrowCursor));
 	m_view->setObjectUndoMode();
-	if(currItem!=NULL)
+	if(currItem!=nullptr)
 		cmen = new ContextMenu(*(m_doc->m_Selection), m_ScMW, m_doc);
 	else
 		cmen = new ContextMenu(m_ScMW, m_doc, mx, my);

Modified: trunk/Scribus/scribus/canvasmode_editweldpoint.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_editweldpoint.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_editweldpoint.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_editweldpoint.cpp	Wed May  2 22:17:14 2018
@@ -69,8 +69,8 @@
 	m_selectedPoint(-1),
 	m_ScMW(view->m_ScMW),
 	m_keyRepeat(false),
-	m_currItem(NULL),
-	m_ModeDialog(NULL),
+	m_currItem(nullptr),
+	m_ModeDialog(nullptr),
 	m_editWeldMode(true)
 {
 }
@@ -78,7 +78,7 @@
 inline bool CanvasMode_EditWeldPoint::GetItem(PageItem** pi)
 {
 	*pi = m_doc->m_Selection->itemAt(0);
-	return (*pi) != NULL;
+	return (*pi) != nullptr;
 }
 
 void CanvasMode_EditWeldPoint::drawControls(QPainter* p)

Modified: trunk/Scribus/scribus/canvasmode_eyedropper.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_eyedropper.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_eyedropper.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_eyedropper.cpp	Wed May  2 22:17:14 2018
@@ -193,7 +193,7 @@
 		for (uint i = 0; i < docSelectionCount; ++i)
 		{
 			PageItem *currItem=m_doc->m_Selection->itemAt(i);
-			if (currItem!=NULL)
+			if (currItem!=nullptr)
 			{
 				if ((m->modifiers() & Qt::ControlModifier) && (currItem->asTextFrame() || currItem->asPathText()))
 					m_doc->itemSelection_SetFillColor(colorName); //Text colour

Modified: trunk/Scribus/scribus/canvasmode_imageimport.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_imageimport.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_imageimport.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_imageimport.cpp	Wed May  2 22:17:14 2018
@@ -166,10 +166,10 @@
 	QToolTip::showText(m->globalPos(), m_tipText + "<b></b>", qApp->activeWindow());
 	m->accept();
 	PageItem *item;
-	if((item = m_canvas->itemUnderCursor(m->globalPos())) != NULL)
+	if((item = m_canvas->itemUnderCursor(m->globalPos())) != nullptr)
 	{
 		PageItem_ImageFrame *currItem;
-		if((currItem = item->asImageFrame()) != NULL)
+		if((currItem = item->asImageFrame()) != nullptr)
 			m_view->setCursor(IconManager::instance()->loadCursor("drawimageframe.png"));
 		else
 			m_view->setCursor(QCursor(Qt::ArrowCursor));
@@ -193,10 +193,10 @@
 	PageItem *item;
 	if(m_imageList.size()>0)
 	{
-		if((item = m_canvas->itemUnderCursor(m->globalPos())) != NULL)
+		if((item = m_canvas->itemUnderCursor(m->globalPos())) != nullptr)
 		{
 			PageItem_ImageFrame *currItem;
-			if((currItem = item->asImageFrame()) != NULL)
+			if((currItem = item->asImageFrame()) != nullptr)
 				setImage(currItem);
 		}
 		else

Modified: trunk/Scribus/scribus/canvasmode_objimport.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_objimport.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_objimport.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_objimport.cpp	Wed May  2 22:17:14 2018
@@ -45,8 +45,8 @@
 	CanvasMode(view)
 {
 	m_Mxp = m_Myp = -1;
-	m_mimeData = NULL;
-	m_trSettings = NULL;
+	m_mimeData = nullptr;
+	m_trSettings = nullptr;
 }
 
 CanvasMode_ObjImport::~CanvasMode_ObjImport()
@@ -112,8 +112,8 @@
 void CanvasMode_ObjImport::deactivate(bool forGesture)
 {
 //	qDebug() << "CanvasMode_ObjImport::deactivate" << forGesture;
-	setMimeData(NULL);
-	setTransactionSettings(NULL);
+	setMimeData(nullptr);
+	setTransactionSettings(nullptr);
 	m_view->setRedrawMarkerShown(false);
 }
 

Modified: trunk/Scribus/scribus/canvasmode_rotate.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/canvasmode_rotate.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_rotate.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_rotate.cpp	Wed May  2 22:17:14 2018
@@ -51,7 +51,7 @@
 inline bool CanvasMode_Rotate::GetItem(PageItem** pi)
 { 
 	*pi = m_doc->m_Selection->itemAt(0); 
-	return (*pi) != NULL; 
+	return (*pi) != nullptr;
 }
 
 void CanvasMode_Rotate::drawControls(QPainter* p)
@@ -452,10 +452,10 @@
 
 void CanvasMode_Rotate::createContextMenu(PageItem* currItem, double mx, double my)
 {
-	ContextMenu* cmen=NULL;
+	ContextMenu* cmen=nullptr;
 	m_view->setObjectUndoMode();
 	m_canvasPressCoord.setXY(mx, my);
-	if(currItem!=NULL)
+	if(currItem!=nullptr)
 		cmen = new ContextMenu(*(m_doc->m_Selection), m_view->m_ScMW, m_doc);
 	else
 		cmen = new ContextMenu(m_view->m_ScMW, m_doc, mx, my);

Modified: trunk/Scribus/scribus/colormgmt/scciedata.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/scciedata.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/scciedata.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/scciedata.cpp	Wed May  2 22:17:14 2018
@@ -8,7 +8,7 @@
 #include "scciedata.h"
 
 // Init the singleton's "self" address to NULL
-ScCIEData* ScCIEData::m_instance = NULL;
+ScCIEData* ScCIEData::m_instance = nullptr;
 
 // Singleton's public constructor
 const ScCIEData& ScCIEData::instance()
@@ -44,4 +44,4 @@
 	if (observer == Observer_10deg)
 		return m_cie1964Observer;
 	return m_cie1931Observer;
-}
+}

Modified: trunk/Scribus/scribus/colormgmt/sccolormgmtengine.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sccolormgmtengine.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sccolormgmtengine.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sccolormgmtengine.cpp	Wed May  2 22:17:14 2018
@@ -10,7 +10,7 @@
 
 ScColorMgmtEngine::ScColorMgmtEngine(ScColorMgmtEngineData* data) : m_data(data)
 {
-	assert(data != NULL);
+	assert(data != nullptr);
 }
 
 int ScColorMgmtEngine::engineID() const
@@ -87,4 +87,4 @@
 bool ScColorMgmtEngine::operator!=(const ScColorMgmtEngine& other) const
 {
 	return m_data != other.m_data;
-}
+}

Modified: trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp	Wed May  2 22:17:14 2018
@@ -48,7 +48,7 @@
 	if ((!d.exists()) || (d.count() == 0))
 		return profileInfos;
 
-	cmsHPROFILE hIn = NULL;
+	cmsHPROFILE hIn = nullptr;
 
 	for (uint dc = 0; dc < d.count(); ++dc)
 	{
@@ -81,10 +81,10 @@
 		{
 			const QByteArray profilePath( QString(directory + "/" + file).toLocal8Bit() );
 			hIn = cmsOpenProfileFromFile(profilePath.data(), "r");
-			if (hIn == NULL)
+			if (hIn == nullptr)
 				continue;
 #ifdef _WIN32
-			cmsUInt32Number descSize = cmsGetProfileInfo(hIn, cmsInfoDescription, "en", "US", NULL, 0);
+			cmsUInt32Number descSize = cmsGetProfileInfo(hIn, cmsInfoDescription, "en", "US", nullptr, 0);
 			if (descSize > 0)
 			{
 				wchar_t* descData = (wchar_t*) malloc(descSize + sizeof(wchar_t));
@@ -102,7 +102,7 @@
 				}
 			}
 #else
-			cmsUInt32Number descSize = cmsGetProfileInfoASCII(hIn, cmsInfoDescription, "en", "US", NULL, 0);
+			cmsUInt32Number descSize = cmsGetProfileInfoASCII(hIn, cmsInfoDescription, "en", "US", nullptr, 0);
 			if (descSize > 0)
 			{
 				char* descData = (char*) malloc(descSize + sizeof(char));
@@ -125,7 +125,7 @@
 			profileInfo.deviceClass = translateLcmsProfileClass( cmsGetDeviceClass(hIn) );
 			profileInfos.append(profileInfo);
 			cmsCloseProfile(hIn);
-			hIn = NULL;
+			hIn = nullptr;
 		}
 	}
 
@@ -138,7 +138,7 @@
 	ScColorProfile profile = m_profileCache->profile(filePath);
 	if (!profile.isNull())
 		return profile;
-	cmsHPROFILE lcmsProf = NULL;
+	cmsHPROFILE lcmsProf = nullptr;
 	QFile file(filePath);
 	if (file.open(QFile::ReadOnly))
 	{
@@ -159,7 +159,7 @@
 			if (profile.isNull() && lcmsProf)
 			{
 				cmsCloseProfile(lcmsProf);
-				lcmsProf = NULL;
+				lcmsProf = nullptr;
 			}
 		}
 		file.close();
@@ -183,7 +183,7 @@
 	if (profile.isNull() && lcmsProf)
 	{
 		cmsCloseProfile(lcmsProf);
-		lcmsProf = NULL;
+		lcmsProf = nullptr;
 	}
 	return profile;
 }
@@ -206,7 +206,7 @@
 	if (profile.isNull() && lcmsProf)
 	{
 		cmsCloseProfile(lcmsProf);
-		lcmsProf = NULL;
+		lcmsProf = nullptr;
 	}
 	return profile;
 }
@@ -218,7 +218,7 @@
 	if (!profile.isNull())
 		return profile;
 
-	cmsHPROFILE lcmsProf = cmsCreateLab4Profile(NULL);
+	cmsHPROFILE lcmsProf = cmsCreateLab4Profile(nullptr);
 	if (lcmsProf)
 	{
 		ScLcms2ColorProfileImpl* profData = new ScLcms2ColorProfileImpl(engine, lcmsProf);
@@ -229,7 +229,7 @@
 	if (profile.isNull() && lcmsProf)
 	{
 		cmsCloseProfile(lcmsProf);
-		lcmsProf = NULL;
+		lcmsProf = nullptr;
 	}
 	return profile;
 }
@@ -239,7 +239,7 @@
 	                             const ScColorProfile& outputProfile, eColorFormat outputFormat,
                                  eRenderIntent renderIntent, long transformFlags)
 {
-	ScColorTransform transform(NULL);
+	ScColorTransform transform(nullptr);
 	if (inputProfile.isNull() || outputProfile.isNull())
 		return transform;
 	int inputProfEngineID  = inputProfile.engine().engineID();
@@ -291,7 +291,7 @@
 		int   lcmsIntent    = translateIntentToLcmsIntent(renderIntent);
 		if (nullTransform)
 			lcmsFlags |= cmsFLAGS_NULLTRANSFORM;
-		cmsHTRANSFORM hTransform = NULL;
+		cmsHTRANSFORM hTransform = nullptr;
 		hTransform = cmsCreateTransform(lcmsInputProf->m_profileHandle , lcmsInputFmt, 
 										lcmsOutputProf->m_profileHandle, lcmsOutputFmt, 
 										lcmsIntent, lcmsFlags | cmsFLAGS_LOWRESPRECALC);
@@ -312,7 +312,7 @@
                                              const ScColorProfile& proofProfile , eRenderIntent renderIntent, 
                                              eRenderIntent proofingIntent, long transformFlags)
 {
-	ScColorTransform transform(NULL);
+	ScColorTransform transform(nullptr);
 	if (inputProfile.isNull() || outputProfile.isNull())
 		return transform;
 	int inputProfEngineID  = inputProfile.engine().engineID();
@@ -359,7 +359,7 @@
 		transform = m_transformPool->findTransform(transInfo);
 		if (transform.isNull())
 		{
-			cmsHTRANSFORM hTransform = NULL;
+			cmsHTRANSFORM hTransform = nullptr;
 			hTransform = cmsCreateProofingTransform(lcmsInputProf->m_profileHandle , lcmsInputFmt, 
 													lcmsOutputProf->m_profileHandle, lcmsOutputFmt,
 													lcmsProofingProf->m_profileHandle, lcmsIntent, 
@@ -394,7 +394,7 @@
 		transform = m_transformPool->findTransform(transInfo);
 		if (transform.isNull())
 		{
-			cmsHTRANSFORM hTransform = NULL;
+			cmsHTRANSFORM hTransform = nullptr;
 			hTransform  = cmsCreateTransform(lcmsInputProf->m_profileHandle , lcmsInputFmt, 
 										     lcmsOutputProf->m_profileHandle, lcmsOutputFmt, 
 											 lcmsPrfIntent, lcmsFlags | cmsFLAGS_LOWRESPRECALC);

Modified: trunk/Scribus/scribus/colormgmt/sclcms2colorprofileimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcms2colorprofileimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcms2colorprofileimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcms2colorprofileimpl.cpp	Wed May  2 22:17:14 2018
@@ -22,7 +22,7 @@
 
 bool ScLcms2ColorProfileImpl::isNull() const
 {
-	return (m_profileHandle == NULL);
+	return (m_profileHandle == nullptr);
 }
 
 eColorSpaceType ScLcms2ColorProfileImpl::colorSpace()  const
@@ -46,7 +46,7 @@
 		if (m_profileHandle)
 		{
 #ifdef _WIN32
-			cmsUInt32Number descSize = cmsGetProfileInfo(m_profileHandle, cmsInfoDescription, "en", "US", NULL, 0);
+			cmsUInt32Number descSize = cmsGetProfileInfo(m_profileHandle, cmsInfoDescription, "en", "US", nullptr, 0);
 			if (descSize > 0)
 			{
 				wchar_t* descData = (wchar_t*) malloc(descSize + sizeof(wchar_t));
@@ -64,7 +64,7 @@
 				}
 			}
 #else
-			cmsUInt32Number descSize = cmsGetProfileInfoASCII(m_profileHandle, cmsInfoDescription, "en", "US", NULL, 0);
+			cmsUInt32Number descSize = cmsGetProfileInfoASCII(m_profileHandle, cmsInfoDescription, "en", "US", nullptr, 0);
 			if (descSize > 0)
 			{
 				char* descData = (char*) malloc(descSize + sizeof(char));
@@ -86,6 +86,6 @@
 	if (m_profileHandle)
 	{
 		cmsCloseProfile(m_profileHandle);
-		m_profileHandle = NULL;
+		m_profileHandle = nullptr;
 	}
-}
+}

Modified: trunk/Scribus/scribus/colormgmt/sclcms2colortransformimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcms2colortransformimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcms2colortransformimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcms2colortransformimpl.cpp	Wed May  2 22:17:14 2018
@@ -21,7 +21,7 @@
 
 bool ScLcms2ColorTransformImpl::isNull() const
 {
-	return (m_transformHandle == NULL);
+	return (m_transformHandle == nullptr);
 }
 
 bool ScLcms2ColorTransformImpl::apply(void* input, void* output, uint numElem)
@@ -49,7 +49,7 @@
 	if (m_transformHandle)
 	{
 		cmsDeleteTransform(m_transformHandle);
-		m_transformHandle = NULL;
+		m_transformHandle = nullptr;
 	}
 }
 

Modified: trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp	Wed May  2 22:17:14 2018
@@ -45,7 +45,7 @@
 		return profileInfos;
 
 	QString nam = "";
-	cmsHPROFILE hIn = NULL;
+	cmsHPROFILE hIn = nullptr;
 
 	for (uint dc = 0; dc < d.count(); ++dc)
 	{
@@ -81,7 +81,7 @@
 			try
 			{
 				hIn = cmsOpenProfileFromFile(profilePath.data(), "r");
-				if (hIn == NULL)
+				if (hIn == nullptr)
 					continue;
 				const char* profileDescriptor = cmsTakeProductDesc(hIn);
 				profileInfo.description = QString(profileDescriptor);
@@ -96,7 +96,7 @@
 				profileInfo.deviceClass = translateLcmsProfileClass( cmsGetDeviceClass(hIn) );
 				profileInfos.append(profileInfo);
 				cmsCloseProfile(hIn);
-				hIn = NULL;
+				hIn = nullptr;
 			}
 			catch (lcmsException&)
 			{
@@ -104,15 +104,15 @@
 				if (hIn)
 				{
 					cmsCloseProfile(hIn);
-					hIn = NULL;
+					hIn = nullptr;
 				}
 				profileInfo.debug = QString("Color profile %1 is broken").arg(fi.filePath());
 				profileInfos.append(profileInfo);
 			}
-			cmsSetErrorHandler(NULL);
-		}
-	}
-	cmsSetErrorHandler(NULL);
+			cmsSetErrorHandler(nullptr);
+		}
+	}
+	cmsSetErrorHandler(nullptr);
 
 	return profileInfos;
 }
@@ -123,7 +123,7 @@
 	ScColorProfile profile = m_profileCache->profile(filePath);
 	if (!profile.isNull())
 		return profile;
-	cmsHPROFILE lcmsProf = NULL;
+	cmsHPROFILE lcmsProf = nullptr;
 	cmsSetErrorHandler(&cmsErrorHandler);
 	try
 	{
@@ -147,7 +147,7 @@
 				if (profile.isNull() && lcmsProf)
 				{
 					cmsCloseProfile(lcmsProf);
-					lcmsProf = NULL;
+					lcmsProf = nullptr;
 				}
 			}
 			file.close();
@@ -160,14 +160,14 @@
 			cmsCloseProfile(lcmsProf);
 		profile = ScColorProfile();
 	}
-	cmsSetErrorHandler(NULL);
+	cmsSetErrorHandler(nullptr);
 	return profile;
 }
 
 ScColorProfile ScLcmsColorMgmtEngineImpl::openProfileFromMem(ScColorMgmtEngine& engine, const QByteArray& data)
 {
 	ScColorProfile profile;
-	cmsHPROFILE lcmsProf = NULL;
+	cmsHPROFILE lcmsProf = nullptr;
 	cmsSetErrorHandler(&cmsErrorHandler);
 	try
 	{
@@ -184,7 +184,7 @@
 		if (profile.isNull() && lcmsProf)
 		{
 			cmsCloseProfile(lcmsProf);
-			lcmsProf = NULL;
+			lcmsProf = nullptr;
 		}
 	}
 	catch (lcmsException& e)
@@ -194,7 +194,7 @@
 			cmsCloseProfile(lcmsProf);
 		profile = ScColorProfile();
 	}
-	cmsSetErrorHandler(NULL);
+	cmsSetErrorHandler(nullptr);
 	return profile;
 }
 
@@ -205,7 +205,7 @@
 	if (!profile.isNull())
 		return profile;
 
-	cmsHPROFILE lcmsProf = NULL;
+	cmsHPROFILE lcmsProf = nullptr;
 	cmsSetErrorHandler(&cmsErrorHandler);
 	try
 	{
@@ -220,7 +220,7 @@
 		if (profile.isNull() && lcmsProf)
 		{
 			cmsCloseProfile(lcmsProf);
-			lcmsProf = NULL;
+			lcmsProf = nullptr;
 		}
 	}
 	catch (lcmsException& e)
@@ -230,7 +230,7 @@
 			cmsCloseProfile(lcmsProf);
 		profile = ScColorProfile();
 	}
-	cmsSetErrorHandler(NULL);
+	cmsSetErrorHandler(nullptr);
 	return profile;
 }
 
@@ -241,11 +241,11 @@
 	if (!profile.isNull())
 		return profile;
 
-	cmsHPROFILE lcmsProf = NULL;
+	cmsHPROFILE lcmsProf = nullptr;
 	cmsSetErrorHandler(&cmsErrorHandler);
 	try
 	{
-		lcmsProf = cmsCreateLabProfile(NULL);
+		lcmsProf = cmsCreateLabProfile(nullptr);
 		if (lcmsProf)
 		{
 			ScLcmsColorProfileImpl* profData = new ScLcmsColorProfileImpl(engine, lcmsProf);
@@ -256,7 +256,7 @@
 		if (profile.isNull() && lcmsProf)
 		{
 			cmsCloseProfile(lcmsProf);
-			lcmsProf = NULL;
+			lcmsProf = nullptr;
 		}
 	}
 	catch (lcmsException& e)
@@ -266,7 +266,7 @@
 			cmsCloseProfile(lcmsProf);
 		profile = ScColorProfile();
 	}
-	cmsSetErrorHandler(NULL);
+	cmsSetErrorHandler(nullptr);
 	return profile;
 }
 
@@ -275,7 +275,7 @@
 	                             const ScColorProfile& outputProfile, eColorFormat outputFormat,
                                  eRenderIntent renderIntent, long transformFlags)
 {
-	ScColorTransform transform(NULL);
+	ScColorTransform transform(nullptr);
 	if (inputProfile.isNull() || outputProfile.isNull())
 		return transform;
 	int inputProfEngineID  = inputProfile.engine().engineID();
@@ -327,7 +327,7 @@
 		int   lcmsIntent    = translateIntentToLcmsIntent(renderIntent);
 		if (nullTransform)
 			lcmsFlags |= cmsFLAGS_NULLTRANSFORM;
-		cmsHTRANSFORM hTransform = NULL;
+		cmsHTRANSFORM hTransform = nullptr;
 		cmsSetErrorHandler(&cmsErrorHandler);
 		try
 		{
@@ -350,7 +350,7 @@
 				cmsDeleteTransform(hTransform);*/
 			transform = ScColorTransform();
 		}
-		cmsSetErrorHandler(NULL);
+		cmsSetErrorHandler(nullptr);
 	}
 	return transform;
 }
@@ -361,7 +361,7 @@
                                              const ScColorProfile& proofProfile , eRenderIntent renderIntent, 
                                              eRenderIntent proofingIntent, long transformFlags)
 {
-	ScColorTransform transform(NULL);
+	ScColorTransform transform(nullptr);
 	if (inputProfile.isNull() || outputProfile.isNull())
 		return transform;
 	int inputProfEngineID  = inputProfile.engine().engineID();
@@ -409,7 +409,7 @@
 		if (transform.isNull())
 		{
 			cmsSetErrorHandler(&cmsErrorHandler);
-			cmsHTRANSFORM hTransform = NULL;
+			cmsHTRANSFORM hTransform = nullptr;
 			try
 			{
 				hTransform = cmsCreateProofingTransform(lcmsInputProf->m_profileHandle , lcmsInputFmt, 
@@ -432,7 +432,7 @@
 					cmsDeleteTransform(hTransform);*/
 				transform = ScColorTransform();
 			}
-			cmsSetErrorHandler(NULL);
+			cmsSetErrorHandler(nullptr);
 		}
 	}
 	else
@@ -457,7 +457,7 @@
 		if (transform.isNull())
 		{
 			cmsSetErrorHandler(&cmsErrorHandler);
-			cmsHTRANSFORM hTransform = NULL;
+			cmsHTRANSFORM hTransform = nullptr;
 			try
 			{
 				hTransform  = cmsCreateTransform(lcmsInputProf->m_profileHandle , lcmsInputFmt, 
@@ -479,7 +479,7 @@
 					cmsDeleteTransform(hTransform);*/
 				transform = ScColorTransform();
 			}
-			cmsSetErrorHandler(NULL);
+			cmsSetErrorHandler(nullptr);
 		}
 	}
 	return transform;

Modified: trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.cpp	Wed May  2 22:17:14 2018
@@ -21,7 +21,7 @@
 
 bool ScLcmsColorProfileImpl::isNull() const
 {
-	return (m_profileHandle == NULL);
+	return (m_profileHandle == nullptr);
 }
 
 eColorSpaceType ScLcmsColorProfileImpl::colorSpace()  const
@@ -52,11 +52,11 @@
 	return m_productDescription;
 }
 
-void ScLcmsColorProfileImpl::closeProfile(void)
+void ScLcmsColorProfileImpl::closeProfile()
 {
 	if (m_profileHandle)
 	{
 		cmsCloseProfile(m_profileHandle);
-		m_profileHandle = NULL;
+		m_profileHandle = nullptr;
 	}
-}
+}

Modified: trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.h
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.h	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcmscolorprofileimpl.h	Wed May  2 22:17:14 2018
@@ -32,7 +32,7 @@
 	cmsHPROFILE     m_profileHandle;
 	mutable QString m_productDescription;
 
-	void closeProfile(void);
+	void closeProfile();
 };
 
 #endif

Modified: trunk/Scribus/scribus/colormgmt/sclcmscolortransformimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/colormgmt/sclcmscolortransformimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcmscolortransformimpl.cpp	(original)
+++ trunk/Scribus/scribus/colormgmt/sclcmscolortransformimpl.cpp	Wed May  2 22:17:14 2018
@@ -21,7 +21,7 @@
 
 bool ScLcmsColorTransformImpl::isNull() const
 {
-	return (m_transformHandle == NULL);
+	return (m_transformHandle == nullptr);
 }
 
 bool ScLcmsColorTransformImpl::apply(void* input, void* output, uint numElem)
@@ -49,7 +49,7 @@
 	if (m_transformHandle)
 	{
 		cmsDeleteTransform(m_transformHandle);
-		m_transformHandle = NULL;
+		m_transformHandle = nullptr;
 	}
 }
 

Modified: trunk/Scribus/scribus/fonts/ftface.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/fonts/ftface.cpp
==============================================================================
--- trunk/Scribus/scribus/fonts/ftface.cpp	(original)
+++ trunk/Scribus/scribus/fonts/ftface.cpp	Wed May  2 22:17:14 2018
@@ -20,7 +20,7 @@
 #include "fonts/scfontmetrics.h"
 
 // static:
-FT_Library FtFace::m_library = NULL;
+FT_Library FtFace::m_library = nullptr;
 
 /*****
    ScFace lifecycle:  unchecked -> loaded -> glyphs checked
@@ -43,7 +43,7 @@
 FtFace::FtFace(QString fam, QString sty, QString vari, QString scname, 
 			   QString psname, QString path, int face, QStringList features)
 : ScFaceData(),
-	m_face(NULL),
+	m_face(nullptr),
 	m_isBold(false),
 	m_isItalic(false),
 	m_encoding(0.0),
@@ -82,7 +82,7 @@
 	if (!m_face) {
 		if (FT_New_Face( m_library, QFile::encodeName(fontFile), faceIndex, & m_face )) {
 			status = ScFace::BROKEN;
-			m_face = NULL;
+			m_face = nullptr;
 			sDebug(QObject::tr("Font %1(%2) is broken").arg(fontFile).arg(faceIndex));
 		}
 		else {
@@ -99,7 +99,7 @@
 	if (!m_face) {
 		if (FT_New_Face( m_library, QFile::encodeName(fontFile), faceIndex, & m_face )) {
 			status = ScFace::BROKEN;
-			m_face = NULL;
+			m_face = nullptr;
 			sDebug(QObject::tr("Font %1(%2) is broken").arg(fontFile).arg(faceIndex));
 			return;
 		}
@@ -183,7 +183,7 @@
 {
 	if (m_face) {
 		FT_Done_Face( m_face );
-		m_face = NULL;
+		m_face = nullptr;
 	}
 	// clear caches
 	ScFaceData::unload();

Modified: trunk/Scribus/scribus/fonts/scface.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/fonts/scface.cpp
==============================================================================
--- trunk/Scribus/scribus/fonts/scface.cpp	(original)
+++ trunk/Scribus/scribus/fonts/scface.cpp	Wed May  2 22:17:14 2018
@@ -37,7 +37,7 @@
 	hasGlyphNames(false),
 	maxGlyph(0),
 	m_cachedStatus(ScFace::UNKNOWN),
-	m_hbFont(NULL)
+	m_hbFont(nullptr)
 {
 }
 
@@ -46,7 +46,7 @@
 	if (m_hbFont)
 	{
 		hb_font_destroy(reinterpret_cast<hb_font_t*>(m_hbFont));
-		m_hbFont = NULL;
+		m_hbFont = nullptr;
 	}
 }
 
@@ -57,17 +57,17 @@
 	FT_Byte *buffer;
 	FT_ULong length = 0;
 
-	if (FT_Load_Sfnt_Table(ftFace, tag, 0, NULL, &length))
-		return NULL;
+	if (FT_Load_Sfnt_Table(ftFace, tag, 0, nullptr, &length))
+		return nullptr;
 
 	buffer = reinterpret_cast<FT_Byte*>(malloc(length));
-	if (buffer == NULL)
-		return NULL;
+	if (buffer == nullptr)
+		return nullptr;
 
 	if (FT_Load_Sfnt_Table(ftFace, tag, 0, buffer, &length))
 	{
 		free(buffer);
-		return NULL;
+		return nullptr;
 	}
 
 	return hb_blob_create((const char *) buffer, length, HB_MEMORY_MODE_WRITABLE, buffer, free);
@@ -79,7 +79,7 @@
 	{
 		FT_Face face = ftFace();
 		if (!face)
-			return NULL;
+			return nullptr;
 
 		// #14699: Harfbuzz internal functions apparently do not support font with a single Apple Roman CMap
 		// Force use of FreeType function in such case

Modified: trunk/Scribus/scribus/fonts/sfnt.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/fonts/sfnt.cpp
==============================================================================
--- trunk/Scribus/scribus/fonts/sfnt.cpp	(original)
+++ trunk/Scribus/scribus/fonts/sfnt.cpp	Wed May  2 22:17:14 2018
@@ -336,7 +336,7 @@
 {
 	QByteArray postData;
 	FT_ULong size = 0;
-	int error = FT_Load_Sfnt_Table ( face, TTAG_post , 0, NULL, &size );
+	int error = FT_Load_Sfnt_Table ( face, TTAG_post , 0, nullptr, &size );
 	//qDebug() << "load post" << error << size;
 	if (error || size == 0)
 	{

Modified: trunk/Scribus/scribus/fpointarray.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/fpointarray.cpp
==============================================================================
--- trunk/Scribus/scribus/fpointarray.cpp	(original)
+++ trunk/Scribus/scribus/fpointarray.cpp	Wed May  2 22:17:14 2018
@@ -51,7 +51,7 @@
 FPointArray & FPointArray::operator=( const FPointArray &a )
 { 
 	QVector<FPoint>::operator=(a);
-	m_svgState = NULL;
+	m_svgState = nullptr;
 	QVector<FPoint>::squeeze();
 	return *this; 
 }

Modified: trunk/Scribus/scribus/gtgettext.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/gtgettext.cpp
==============================================================================
--- trunk/Scribus/scribus/gtgettext.cpp	(original)
+++ trunk/Scribus/scribus/gtgettext.cpp	Wed May  2 22:17:14 2018
@@ -37,7 +37,7 @@
 // Constructor
 gtGetText::gtGetText(ScribusDoc* doc)
 {
-	m_dias = NULL;
+	m_dias = nullptr;
 	// Attach to the active document
 	m_Doc = doc;
 	// Load the plugins array.
@@ -246,7 +246,7 @@
 	QString pluginFilePath = QString("%1/gettext/%2").arg(ScPaths::instance().pluginDir(), idata.soFilePath);
 	// Attempt to load the plugin, store the pointer in gtplugin
 	gtplugin = PluginManager::loadDLL(pluginFilePath);
-	// If gtplugin is NULL we failed to load the plugin. Report an error to the user and exit the method.
+	// If gtplugin is nullptr we failed to load the plugin. Report an error to the user and exit the method.
 	if (!gtplugin)
 	{
 		qWarning("Failed to load plugin %s", pluginFilePath.toLatin1().constData());
@@ -265,7 +265,7 @@
 	{
 		// Attempt to map the old GetText method to to the pointer via the PluginManager. Store the result in fp_GetText.
 		fp_GetText = (sdem) PluginManager::resolveSym(gtplugin,"GetText");
-		// If fp_GetText is NULL, we could not find the symbol,report the error, unload the "DLL" and exit the method.
+		// If fp_GetText is nullptr, we could not find the symbol,report the error, unload the "DLL" and exit the method.
 		if (fp_GetText)
 		{
 			// Create a new writer object in "append"'s mode (true or false ) attached to the importItem
@@ -305,7 +305,7 @@
 	QString pluginFilePath = QString("%1/gettext/%2").arg(ScPaths::instance().pluginDir(), name);
 	// Attempt to load the plugin.
 	gtplugin = PluginManager::loadDLL(pluginFilePath);
-	// if gtplugin is NULL we were unable to load the plugin. Return an error and exit the method.
+	// if gtplugin is nullptr we were unable to load the plugin. Return an error and exit the method.
 	if (!gtplugin)
 	{
 		qWarning("Failed to load plugin %s", pluginFilePath.toLatin1().constData());
@@ -313,7 +313,7 @@
 	}
 	// Attempt to resolve the plugin symbol to the importer name (FileFormatName)
 	fp_FileFormatName = (sdem0) PluginManager::resolveSym( gtplugin, "FileFormatName");
-	// if fp_FileFormatName is NULL, we could not find the FileFormatName symbol. The plugin is incomplete.
+	// if fp_FileFormatName is nullptr, we could not find the FileFormatName symbol. The plugin is incomplete.
 	// Report an error, unload the plugin, and exit the method.
 	if (!fp_FileFormatName)
 	{
@@ -323,7 +323,7 @@
 	}
 	// Attempt to resolve the plugin symbol to the list of supported file extensions.
 	fp_FileExtensions = (sdem1) PluginManager::resolveSym( gtplugin, "FileExtensions");
-	// if fp_FileExtensions is NULL, we could not find the FileExtensions symbol. The plugin is incomplete.
+	// if fp_FileExtensions is nullptr, we could not find the FileExtensions symbol. The plugin is incomplete.
 	// Report an error, unload the plugin, and exit the method.
 	if (!fp_FileExtensions)
 	{

Modified: trunk/Scribus/scribus/gtwriter.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/gtwriter.cpp
==============================================================================
--- trunk/Scribus/scribus/gtwriter.cpp	(original)
+++ trunk/Scribus/scribus/gtwriter.cpp	Wed May  2 22:17:14 2018
@@ -47,8 +47,8 @@
 gtWriter::gtWriter(bool append, PageItem *pageitem)
 {
 	m_action = new gtAction(append, pageitem);
-	m_defaultStyle = NULL;
-	m_currentStyle = NULL;
+	m_defaultStyle = nullptr;
+	m_currentStyle = nullptr;
 	m_errorSet = false;
 
 	m_action->setProgressInfo();
@@ -88,12 +88,12 @@
 
 void gtWriter::unsetParagraphStyle()
 {
-	m_paragraphStyle = NULL;
+	m_paragraphStyle = nullptr;
 }
 
 void gtWriter::unsetCharacterStyle()
 {
-	m_characterStyle = NULL;
+	m_characterStyle = nullptr;
 }
 
 double gtWriter::getPreferredLineSpacing(int fontSize)
@@ -114,11 +114,11 @@
 		return;
 	if (inNote && !inNoteBody)
 		return;
-	if (m_characterStyle != NULL)
+	if (m_characterStyle != nullptr)
 	{
 		m_action->write(text, m_characterStyle, inNote);
 	}
-	else if (m_paragraphStyle != NULL)
+	else if (m_paragraphStyle != nullptr)
 	{
 		m_action->write(text, m_paragraphStyle, inNote);
 	}
@@ -153,7 +153,7 @@
 {
 	if (inNote && !inNoteBody)
 		return;
-	if (style == NULL)
+	if (style == nullptr)
 	{
 		append(text);
 		return;
@@ -161,7 +161,7 @@
 
 	m_currentStyle = style;
 	m_action->write(text, style, inNote);
-	m_currentStyle = NULL;
+	m_currentStyle = nullptr;
 }
 
 void gtWriter::append(const QString& text, gtStyle *style, bool updatePStyle)

Modified: trunk/Scribus/scribus/guidemanagercore.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/guidemanagercore.cpp
==============================================================================
--- trunk/Scribus/scribus/guidemanagercore.cpp	(original)
+++ trunk/Scribus/scribus/guidemanagercore.cpp	Wed May  2 22:17:14 2018
@@ -243,9 +243,9 @@
 	Guides guides;
 	int value = m_horizontalAutoCount;
 	
-	if (page == NULL)
+	if (page == nullptr)
 		page = m_page;
-	if (page == NULL)
+	if (page == nullptr)
 		return guides;
 	if (m_horizontalAutoCount == 0)
 		return guides;
@@ -290,9 +290,9 @@
 	Guides guides;
 	int value = m_verticalAutoCount;
 	
-	if (page == NULL)
+	if (page == nullptr)
 		page = m_page;
-	if (page == NULL)
+	if (page == nullptr)
 		return guides;
 	if (m_verticalAutoCount == 0)
 		return guides;

Modified: trunk/Scribus/scribus/guidemanagercore.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/guidemanagercore.h
==============================================================================
--- trunk/Scribus/scribus/guidemanagercore.h	(original)
+++ trunk/Scribus/scribus/guidemanagercore.h	Wed May  2 22:17:14 2018
@@ -56,8 +56,8 @@
 	double horizontal(uint ix, GuideType type);
 	double vertical(uint ix, GuideType type);
 
-	Guides getAutoHorizontals(ScPage* page = NULL);
-	Guides getAutoVerticals(ScPage* page = NULL);
+	Guides getAutoHorizontals(ScPage* page = nullptr);
+	Guides getAutoVerticals(ScPage* page = nullptr);
 
 	void clearHorizontals(GuideType type);
 	void clearVerticals(GuideType type);

Modified: trunk/Scribus/scribus/imagedataloaders/scimgdataloader_gmagick.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/imagedataloaders/scimgdataloader_gmagick.cpp
==============================================================================
--- trunk/Scribus/scribus/imagedataloaders/scimgdataloader_gmagick.cpp	(original)
+++ trunk/Scribus/scribus/imagedataloaders/scimgdataloader_gmagick.cpp	Wed May  2 22:17:14 2018
@@ -180,7 +180,7 @@
 		layerCount = 0;
 		Image *flatten_image = CloneImage(image, 0, 0, true, &exception);
 		Image *next;
-		if ((flatten_image != (Image *) NULL) && (image->next != (Image *) NULL))
+		if ((flatten_image != (Image *) nullptr) && (image->next != (Image *) nullptr))
 		{
 			bool visible = true;
 			double opacity = 1.0;
@@ -225,7 +225,7 @@
 			{
 				(void)CompositeImage(flatten_image, ClearCompositeOp, flatten_image, flatten_image->page.x, flatten_image->page.y);
 			}
-			for (next = image->next; next != (Image*)NULL; next = next->next)
+			for (next = image->next; next != (Image*)nullptr; next = next->next)
 			{
 				visible = true;
 				opacity = 1.0;

Modified: trunk/Scribus/scribus/imagedataloaders/scimgdataloader_jpeg.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/imagedataloaders/scimgdataloader_jpeg.cpp
==============================================================================
--- trunk/Scribus/scribus/imagedataloaders/scimgdataloader_jpeg.cpp	(original)
+++ trunk/Scribus/scribus/imagedataloaders/scimgdataloader_jpeg.cpp	Wed May  2 22:17:14 2018
@@ -57,7 +57,7 @@
 	FILE     *infile;
 	cinfo.err = jpeg_std_error (&jerr.pub);
 	jerr.pub.error_exit = my_error_exit;
-	infile = NULL;
+	infile = nullptr;
 	if (setjmp (jerr.setjmp_buffer))
 	{
 		jpeg_destroy_decompress (&cinfo);
@@ -67,10 +67,10 @@
 	}
 	jpeg_create_decompress (&cinfo);
 #if defined(Q_OS_WIN32)
-	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == NULL)
+	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == nullptr)
 		return;
 #else
-	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == NULL)
+	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == nullptr)
 		return;
 #endif
 	jpeg_stdio_src(&cinfo, infile);
@@ -132,7 +132,7 @@
 	FILE     *infile;
 	cinfo.err = jpeg_std_error (&jerr.pub);
 	jerr.pub.error_exit = my_error_exit;
-	infile = NULL;
+	infile = nullptr;
 
 	initialize();
 	m_imageInfoRecord.type = ImageTypeJPG;
@@ -146,10 +146,10 @@
 	}
 	jpeg_create_decompress (&cinfo);
 #if defined(Q_OS_WIN32)
-	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == NULL)
+	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == nullptr)
 		return false;
 #else
-	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == NULL)
+	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == nullptr)
 		return false;
 #endif
 	jpeg_stdio_src(&cinfo, infile);
@@ -620,7 +620,7 @@
 	unsigned int data_length[MAX_SEQ_NO+1]; /* size of profile data in marker */
 	unsigned int data_offset[MAX_SEQ_NO+1]; /* offset for data in marker */
 
-	*icc_data_ptr = NULL;		/* avoid confusion if false return */
+	*icc_data_ptr = nullptr;		/* avoid confusion if false return */
 	*icc_data_len = 0;
 
 	/* This first pass over the saved markers discovers whether there are
@@ -630,7 +630,7 @@
 	for (seq_no = 1; seq_no <= MAX_SEQ_NO; seq_no++)
 		marker_present[seq_no] = 0;
 	seq_no = 0;
-	for (marker = cinfo->marker_list; marker != NULL; marker = marker->next)
+	for (marker = cinfo->marker_list; marker != nullptr; marker = marker->next)
 	{
 		if (requestmarker == ICC_MARKER && marker_is_icc(marker))
 		{
@@ -675,11 +675,11 @@
 
 	/* Allocate space for assembled data */
 	icc_data = (JOCTET *) malloc(total_length * sizeof(JOCTET));
-	if (icc_data == NULL)
+	if (icc_data == nullptr)
 		return false;		/* oops, out of memory */
 	seq_no=0;
 	/* and fill it in */
-	for (marker = cinfo->marker_list; marker != NULL; marker = marker->next)
+	for (marker = cinfo->marker_list; marker != nullptr; marker = marker->next)
 	{
 		if ( (requestmarker == ICC_MARKER && marker_is_icc(marker)) ||
 		        (requestmarker == PHOTOSHOP_MARKER && marker_is_photoshop(marker)) || (requestmarker == 0xE1))

Modified: trunk/Scribus/scribus/imagedataloaders/scimgdataloader_ps.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/imagedataloaders/scimgdataloader_ps.cpp
==============================================================================
--- trunk/Scribus/scribus/imagedataloaders/scimgdataloader_ps.cpp	(original)
+++ trunk/Scribus/scribus/imagedataloaders/scimgdataloader_ps.cpp	Wed May  2 22:17:14 2018
@@ -936,7 +936,7 @@
 	FILE     *infile;
 	cinfo.err = jpeg_std_error (&jerr.pub);
 	jerr.pub.error_exit = my_error_exit;
-	infile = NULL;
+	infile = nullptr;
 	if (setjmp (jerr.setjmp_buffer))
 	{
 		jpeg_destroy_decompress (&cinfo);
@@ -946,10 +946,10 @@
 	}
 	jpeg_create_decompress (&cinfo);
 #if defined(Q_OS_WIN32)
-	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == NULL)
+	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == nullptr)
 		return false;
 #else
-	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == NULL)
+	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == nullptr)
 		return false;
 #endif
 	jpeg_stdio_src(&cinfo, infile);
@@ -1061,7 +1061,7 @@
 	FILE     *infile;
 	cinfo.err = jpeg_std_error (&jerr.pub);
 	jerr.pub.error_exit = my_error_exit;
-	infile = NULL;
+	infile = nullptr;
 	if (setjmp (jerr.setjmp_buffer))
 	{
 		jpeg_destroy_decompress (&cinfo);
@@ -1071,10 +1071,10 @@
 	}
 	jpeg_create_decompress (&cinfo);
 #if defined(Q_OS_WIN32)
-	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == NULL)
+	if ((infile = _wfopen((const wchar_t*) fn.utf16(), L"rb")) == nullptr)
 		return false;
 #else
-	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == NULL)
+	if ((infile = fopen (fn.toLocal8Bit(), "rb")) == nullptr)
 		return false;
 #endif
 	jpeg_stdio_src(&cinfo, infile);

Modified: trunk/Scribus/scribus/imagedataloaders/scimgdataloader_tiff.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/imagedataloaders/scimgdataloader_tiff.cpp
==============================================================================
--- trunk/Scribus/scribus/imagedataloaders/scimgdataloader_tiff.cpp	(original)
+++ trunk/Scribus/scribus/imagedataloaders/scimgdataloader_tiff.cpp	Wed May  2 22:17:14 2018
@@ -271,7 +271,7 @@
 				TIFFGetField(tif, TIFFTAG_TILEWIDTH,  &columns);
 				TIFFGetField(tif, TIFFTAG_TILELENGTH, &rows);
 				tile_buf = (uint32*) _TIFFmalloc(columns*rows*sizeof(uint32));
-				if (tile_buf == NULL)
+				if (tile_buf == nullptr)
 				{
 					TIFFClose(tif);
 					return false;

Modified: trunk/Scribus/scribus/observable.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/observable.h
==============================================================================
--- trunk/Scribus/scribus/observable.h	(original)
+++ trunk/Scribus/scribus/observable.h	Wed May  2 22:17:14 2018
@@ -113,7 +113,7 @@
 	friend class UpdateManager;
 	
 public:
-	MassObservable(UpdateManager* um = NULL);
+	MassObservable(UpdateManager* um = nullptr);
 	virtual ~MassObservable();
 	/**
 		Used if the UpdateManager is not available when the constructor is called
@@ -204,7 +204,7 @@
 class SCRIBUS_API Observable : public MassObservable<OBSERVED*> 
 {	
 public:
-	Observable(UpdateManager* um = NULL) : MassObservable<OBSERVED*>(um) {}
+	Observable(UpdateManager* um = nullptr) : MassObservable<OBSERVED*>(um) {}
 	
 	virtual void update() 
 	{ 
@@ -244,7 +244,7 @@
 inline void MassObservable<OBSERVED>::update(OBSERVED what)
 {
 	Private_Memento<OBSERVED>* memento = new Private_Memento<OBSERVED>(what);
-	if (m_um == NULL || m_um->requestUpdate(this, memento))
+	if (m_um == nullptr || m_um->requestUpdate(this, memento))
 	{
 		updateNow(memento);
 	}
@@ -254,7 +254,7 @@
 inline void MassObservable<OBSERVED>::updateLayout(OBSERVED what)
 {
 	Private_Memento<OBSERVED>* memento = new Private_Memento<OBSERVED>(what, true);
-	if (m_um == NULL || m_um->requestUpdate(this, memento))
+	if (m_um == nullptr || m_um->requestUpdate(this, memento))
 		updateNow(memento);
 }
 
@@ -263,7 +263,7 @@
 {
 	Private_Memento<OBSERVED>* memento = dynamic_cast<Private_Memento<OBSERVED>*>(what);
 	if (!memento)
-		qFatal("MassObservable<OBSERVED>::updateNow memento NULL");
+		qFatal("MassObservable<OBSERVED>::updateNow memento nullptr");
 	foreach (Observer<OBSERVED>* obs, m_observers)
 		obs->changed(memento->m_data, memento->m_layout);
 	changedSignal->emitSignal(QVariant::fromValue(memento->m_data));

Modified: trunk/Scribus/scribus/pageitem_textframe.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/pageitem_textframe.h
==============================================================================
--- trunk/Scribus/scribus/pageitem_textframe.h	(original)
+++ trunk/Scribus/scribus/pageitem_textframe.h	Wed May  2 22:17:14 2018
@@ -125,7 +125,7 @@
 
 public:
 	//for footnotes/endnotes
-	bool hasNoteMark(NotesStyle* NS = NULL);
+	bool hasNoteMark(NotesStyle* NS = nullptr);
 	bool hasNoteFrame(NotesStyle* NS, bool inChain = false);
 	//bool hasNoteFrame(PageItem_NoteFrame* nF) { return m_notesFramesMap.contains(nF); }
 	void delAllNoteFrames(bool doUpdate = false);

Modified: trunk/Scribus/scribus/pdflib_core.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/pdflib_core.cpp
==============================================================================
--- trunk/Scribus/scribus/pdflib_core.cpp	(original)
+++ trunk/Scribus/scribus/pdflib_core.cpp	Wed May  2 22:17:14 2018
@@ -4038,7 +4038,7 @@
 	getBleeds(ActPageP, bleedLeft, bleedRight);
 	double maxBoxX = ActPageP->width()+bleedRight+bleedLeft;
 	double maxBoxY = ActPageP->height()+Options.bleeds.top()+Options.bleeds.bottom();
-	if (controlItem != NULL)
+	if (controlItem != nullptr)
 	{
 		double groupW, groupH;
 		if (controlItem->isGroup())
@@ -4100,7 +4100,7 @@
 	PutDoc("/K false\n");
 	PutDoc(">>");
 	writer.endObj(Gobj);
-	if (controlItem != NULL)
+	if (controlItem != nullptr)
 	{
 		retString += "q\n";
 		retString += PDF_TransparenzFill(controlItem);
@@ -4124,7 +4124,7 @@
 	getBleeds(ActPageP, bleedLeft, bleedRight);
 	double maxBoxX = ActPageP->width()+bleedRight+bleedLeft;
 	double maxBoxY = ActPageP->height()+Options.bleeds.top()+Options.bleeds.bottom();
-	if (controlItem != NULL)
+	if (controlItem != nullptr)
 	{
 		double groupW, groupH;
 		if (controlItem->isGroup())
@@ -6544,7 +6544,7 @@
 bool PDFLibCore::PDF_PatternFillStroke(QByteArray& output, PageItem *currItem, int kind, bool forArrow)
 {
 	QByteArray tmp2 = "", tmpOut;
-	ScPattern *pat = NULL;
+	ScPattern *pat = nullptr;
 	if (kind == 0)
 	{
 		QString itemPattern = currItem->pattern();
@@ -9801,8 +9801,8 @@
 	try
 	{
 		PoDoFo::PdfPage*   page      = doc->GetPage(qMin(qMax(1, c->pixm.imgInfo.actualPageNumber), c->pixm.imgInfo.numberOfPages) - 1);
-		PoDoFo::PdfObject* contents  = page? page->GetContents() : NULL;
-		PoDoFo::PdfObject* resources = page? page->GetResources() : NULL;
+		PoDoFo::PdfObject* contents  = page? page->GetContents() : nullptr;
+		PoDoFo::PdfObject* resources = page? page->GetResources() : nullptr;
 		for (PoDoFo::PdfObject* par = page->GetObject(); par && !resources; par = par->GetIndirectKey("Parent"))
 		{
 			resources = par->GetIndirectKey("Resources");
@@ -9861,7 +9861,7 @@
 				PutDoc("\n/StructParents " + Pdf::toPdf(xParents)); // required if page uses structured content
 			}
 			*/
-			char * mbuffer = NULL;
+			char * mbuffer = nullptr;
 			long mlen = 0;
 
 #if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(0, 7, 99))
@@ -9981,7 +9981,7 @@
 				copyPoDoFoDirect(nextObj, referencedObjects, importedObjects);
 			}
 
-			char * mbuffer = NULL;
+			char * mbuffer = nullptr;
 			long mlen = 0;
 			// copied from podofoimpose
 			PoDoFo::PdfMemoryOutputStream outMemStream ( 1 );
@@ -9997,7 +9997,7 @@
 				{
 					nextObj = doc->GetObjects().GetObject(carray[ci].GetReference());
 
-					while(nextObj != NULL)
+					while(nextObj != nullptr)
 					{
 
 						if(nextObj->IsReference())
@@ -10158,7 +10158,7 @@
 	if (obj->HasStream())
 	{
 		const PoDoFo::PdfStream* stream = obj->GetStream();
-		char * mbuffer = NULL;
+		char * mbuffer = nullptr;
 		long mlen = 0;
 
 #if (PODOFO_VERSION >= PODOFO_MAKE_VERSION(0, 7, 99))

Modified: trunk/Scribus/scribus/scclocale.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scclocale.cpp
==============================================================================
--- trunk/Scribus/scribus/scclocale.cpp	(original)
+++ trunk/Scribus/scribus/scclocale.cpp	Wed May  2 22:17:14 2018
@@ -28,7 +28,7 @@
 	cLocale = _create_locale(LC_ALL, "C");
 #else
   #if not defined(Q_OS_SOLARIS) and not defined(Q_OS_OPENBSD) and not defined(Q_OS_FREEBSD) and not defined(Q_OS_HAIKU)
-	cLocale = newlocale(LC_ALL_MASK, "C", NULL);
+	cLocale = newlocale(LC_ALL_MASK, "C", nullptr);
   #endif
 #endif
 }
@@ -177,7 +177,7 @@
 
 double ScCLocale::strtod(const char * str, char ** endptr)
 {
-	if (NULL == that()->cLocale)
+	if (nullptr == that()->cLocale)
 	{
 		// a sade workaround
 		double result(0.0);

Modified: trunk/Scribus/scribus/scdocoutput.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scdocoutput.cpp
==============================================================================
--- trunk/Scribus/scribus/scdocoutput.cpp	(original)
+++ trunk/Scribus/scribus/scdocoutput.cpp	Wed May  2 22:17:14 2018
@@ -21,7 +21,7 @@
 	{
 		page = doc->Pages->at( pageNumbers[index] - 1 );
 		ScPageOutput* outputComponent = createPageOutputComponent(index + 1);
-		if (outputComponent != NULL)
+		if (outputComponent != nullptr)
 		{
 			outputComponent->begin();
 			outputComponent->drawPage(page);

Modified: trunk/Scribus/scribus/scfonts.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scfonts.cpp
==============================================================================
--- trunk/Scribus/scribus/scfonts.cpp	(original)
+++ trunk/Scribus/scribus/scfonts.cpp	Wed May  2 22:17:14 2018
@@ -129,7 +129,7 @@
 	//QString::null+/ is / of course.
 	if (path.isEmpty())
 		return;
-	FT_Library library = NULL;
+	FT_Library library = nullptr;
 	QString pathfile, fullpath;
 //	bool error;
 //	error =
@@ -300,9 +300,9 @@
 	if (FT_IS_SFNT(face)) 
 	{
 		FT_ULong ret = 0;
-		bool hasGlyph = ! FT_Load_Sfnt_Table(face, TTAG_glyf, 0, NULL,  &ret);
+		bool hasGlyph = ! FT_Load_Sfnt_Table(face, TTAG_glyf, 0, nullptr,  &ret);
 		hasGlyph &= ret > 0;
-		bool hasCFF = ! FT_Load_Sfnt_Table(face, TTAG_CFF, 0, NULL,  &ret);
+		bool hasCFF = ! FT_Load_Sfnt_Table(face, TTAG_CFF, 0, nullptr,  &ret);
 		hasCFF &= ret > 0;
 		if (hasGlyph)
 			type = ScFace::TTF;
@@ -455,7 +455,7 @@
 {
 	QStringList fontFeaturesList;
 	//get all supported Opentype Features
-	unsigned count = hb_ot_layout_table_get_feature_tags(hb_face, table, 0, NULL, NULL);
+	unsigned count = hb_ot_layout_table_get_feature_tags(hb_face, table, 0, nullptr, nullptr);
 	std::vector<hb_tag_t> features(count);
 	hb_ot_layout_table_get_feature_tags(hb_face, table, 0,  &count, features.data());
 	for (unsigned i = 0; i < count; ++i)
@@ -474,7 +474,7 @@
 {
 	// Create hb-ft font and get hb_face from it
 	hb_font_t *hb_font;
-	hb_font = hb_ft_font_create(face, NULL);
+	hb_font = hb_ft_font_create(face, nullptr);
 	hb_face_t *hb_face = hb_font_get_face(hb_font);
 	//find Opentype Font Features in GSUB table
 	QStringList featuresGSUB = getFontFeaturesFromTable(HB_OT_TAG_GSUB, hb_face);
@@ -494,7 +494,7 @@
 	ScFace t;
 	if (filename.isEmpty())
 		return t;
-	FT_Library library = NULL;
+	FT_Library library = nullptr;
 	bool error;
 	error = FT_Init_FreeType( &library );
 	QFileInfo fi(filename);
@@ -505,11 +505,11 @@
 	QString glyName = "";
 	ScFace::FontFormat format;
 	ScFace::FontType   type;
-	FT_Face         face = NULL;
+	FT_Face         face = nullptr;
 	error = FT_New_Face(library, QFile::encodeName(filename), 0, &face);
-	if (error || (face == NULL))
-	{
-		if (face != NULL)
+	if (error || (face == nullptr))
+	{
+		if (face != nullptr)
 			FT_Done_Face(face);
 		FT_Done_FreeType(library);
 		return t;
@@ -636,7 +636,7 @@
 	QString glyName = "";
 	ScFace::FontFormat format;
 	ScFace::FontType   type;
-	FT_Face         face = NULL;
+	FT_Face         face = nullptr;
 	struct testCache foCache;
 	QFileInfo fic(filename);
 	QDateTime lastMod = fic.lastModified();
@@ -655,9 +655,9 @@
 		ScCore->setSplashStatus( QObject::tr("Creating Font Cache") );
 	}
 	FT_Error error = FT_New_Face( library, QFile::encodeName(filename), 0, &face );
-	if (error || (face == NULL)) 
-	{
-		if (face != NULL)
+	if (error || (face == nullptr))
+	{
+		if (face != nullptr)
 			FT_Done_Face(face);
 		checkedFonts.insert(filename, foCache);
 		if (showFontInformation)
@@ -897,7 +897,7 @@
 		if ((++faceIndex) >= face->num_faces)
 			break;
 		FT_Done_Face(face);
-		face = NULL;
+		face = nullptr;
 		error = FT_New_Face(library, QFile::encodeName(filename), faceIndex, &face);
 	} //while
 	
@@ -984,9 +984,9 @@
 	FcConfig* config = FcInitLoadConfigAndFonts();
 	// The pattern controls what fonts to match. In this case we want to
 	// match all scalable fonts, but ignore bitmap fonts.
-	FcPattern* pat = FcPatternBuild(NULL,
+	FcPattern* pat = FcPatternBuild(nullptr,
 									FC_SCALABLE, FcTypeBool, true,
-									NULL);
+									nullptr);
 	// The ObjectSet tells FontConfig what information about each match to return.
 	// We currently just need FC_FILE, but other info like font family and style
 	// is available - see "man fontconfig".
@@ -1009,12 +1009,12 @@
 	FcPatternDestroy(pat);
 	// Create the Freetype library
 //	bool error;
-	FT_Library library = NULL;
+	FT_Library library = nullptr;
 	FT_Init_FreeType( &library );
 	// Now iterate over the font files and load them
 	for (int i = 0; i < fs->nfont; i++)
 	{
-		FcChar8 *file = NULL;
+		FcChar8 *file = nullptr;
 		if (FcPatternGetString (fs->fonts[i], FC_FILE, 0, &file) == FcResultMatch)
 		{
 			if (showFontInformation)
@@ -1034,7 +1034,7 @@
 void SCFonts::AddXFontPath()
 {
 	int pathcount,i;
-	Display *display=XOpenDisplay(NULL);
+	Display *display=XOpenDisplay(nullptr);
 	char **fontpath=XGetFontPath(display,&pathcount);
 	for(i=0; i<pathcount; ++i)
 		AddPath(fontpath[i]);

Modified: trunk/Scribus/scribus/sclayer.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/sclayer.cpp
==============================================================================
--- trunk/Scribus/scribus/sclayer.cpp	(original)
+++ trunk/Scribus/scribus/sclayer.cpp	Wed May  2 22:17:14 2018
@@ -1,3 +1,5 @@
+#include <utility>
+
 /*
 For general Scribus (>=1.3.2) copyright and licensing information please refer
 to the COPYING file provided with the program. Following this notice may exist
@@ -12,7 +14,7 @@
 #include <QVector> //necessary to avoid msvc warnings induced by SCRIBUS_API on ScLayers + early instantiation of templates
 #include <QtAlgorithms>
 
-ScLayer::ScLayer(void)
+ScLayer::ScLayer()
 {
 	Name         = QObject::tr("New Layer");
 	ID          = 0;
@@ -87,7 +89,7 @@
 	return false;
 }
 
-int ScLayers::getMaxID(void)
+int ScLayers::getMaxID()
 {
 	int nr, maxNr = -1;
 	for (int i = 0; i < this->count(); ++i)
@@ -99,9 +101,9 @@
 	return maxNr;
 }
 
-const ScLayer*  ScLayers::bottomLayer (void) const
-{
-	const ScLayer* layer, *bLayer = NULL;
+const ScLayer*  ScLayers::bottomLayer () const
+{
+	const ScLayer* layer, *bLayer = nullptr;
 	for (int i = 0; i < this->count(); ++i)
 	{
 		layer = &this->at(i);
@@ -111,9 +113,9 @@
 	return bLayer;
 }
 
-const ScLayer* ScLayers::topLayer(void) const
-{
-	const ScLayer *layer, *tLayer = NULL;
+const ScLayer* ScLayers::topLayer() const
+{
+	const ScLayer *layer, *tLayer = nullptr;
 	for (int i = 0; i < this->count(); ++i)
 	{
 		layer = &this->at(i);
@@ -125,12 +127,12 @@
 
 void ScLayers::levelToLayer (ScLayer& layer, int level) const
 {
-	uint layerCount = count();
-	for (uint la2 = 0; la2 < layerCount; ++la2)
-	{
-		if (this->at(la2).Level == level)
-		{
-			const ScLayer& ll  = this->at(la2);
+	int layerCount = count();
+	for (int i = 0; i < layerCount; ++i)
+	{
+		if (this->at(i).Level == level)
+		{
+			const ScLayer& ll  = this->at(i);
 			layer.isViewable   = ll.isViewable;
 			layer.isPrintable  = ll.isPrintable;
 			layer.isEditable   = ll.isEditable;
@@ -148,28 +150,28 @@
 ScLayer* ScLayers::byLevel(const int level)
 {
 	ScLayers::Iterator itend = end();
-	for (ScLayers::Iterator it = 0; it != itend; ++it)
+	for (ScLayers::Iterator it = nullptr; it != itend; ++it)
 	{
 		if( it->Level == level)
 			return &(*it);
 	}
-	return NULL;
+	return nullptr;
 }
 
 ScLayer* ScLayers::byID(const int nr)
 {
 	ScLayers::Iterator itend = end();
-	for (ScLayers::Iterator it = 0; it != itend; ++it)
+	for (ScLayers::Iterator it = nullptr; it != itend; ++it)
 	{
 		if( it->ID == nr)
 			return &(*it);
 	}
-	return NULL;
-}
-
-ScLayer* ScLayers::bottom(void)
-{
-	ScLayer* bLayer = NULL;
+	return nullptr;
+}
+
+ScLayer* ScLayers::bottom()
+{
+	ScLayer* bLayer = nullptr;
 	ScLayers::Iterator it, itEnd = end();
 	for (it = begin(); it != itEnd; ++it)
 	{
@@ -179,9 +181,9 @@
 	return bLayer;
 }
 
-ScLayer* ScLayers::top(void)
-{
-	ScLayer *tLayer = NULL;
+ScLayer* ScLayers::top()
+{
+	ScLayer *tLayer = nullptr;
 	ScLayers::Iterator it, itEnd = end();
 	for (it = begin(); it != itEnd; ++it)
 	{
@@ -210,7 +212,7 @@
 		}
 		return rlyr;
 	}
-	return NULL;
+	return nullptr;
 }
 
 ScLayer* ScLayers::below (int nr)
@@ -232,43 +234,43 @@
 		}
 		return rlyr;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerByLevel (int level) const
 {
-	const ScLayer *layer = NULL;
+	const ScLayer *layer = nullptr;
 	for (int i = 0; i < this->count(); ++i)
 	{
 		layer = &this->at(i);
 		if( layer->Level == level)
 			return layer;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerByID (int nr) const
 {
-	const ScLayer *layer = NULL;
+	const ScLayer *layer = nullptr;
 	for (int i = 0; i < this->count(); ++i)
 	{
 		layer = &this->at(i);
 		if( layer->ID == nr)
 			return layer;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerByName (const QString& name) const
 {
-	const ScLayer *layer = NULL;
+	const ScLayer *layer = nullptr;
 	for (int i = 0; i < this->count(); ++i)
 	{
 		layer = &this->at(i);
 		if( layer->Name == name)
 			return layer;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerAbove (int level) const
@@ -289,7 +291,7 @@
 		}
 		return retlay;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerAbove (const ScLayer& layer) const
@@ -311,7 +313,7 @@
 		}
 		return retlay;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerBelow (int level) const
@@ -332,7 +334,7 @@
 		}
 		return retlay;
 	}
-	return NULL;
+	return nullptr;
 }
 
 const ScLayer* ScLayers::layerBelow (const ScLayer& layer) const
@@ -354,7 +356,7 @@
 		}
 		return retlay;
 	}
-	return NULL;
+	return nullptr;
 }
 
 int ScLayers::addLayer(const QString& layerName)
@@ -477,7 +479,7 @@
 	return true;
 }
 
-void ScLayers::sort(void)
+void ScLayers::sort()
 {
 	int level = 0;
 	ScLayers::Iterator it, itend = end();
@@ -632,7 +634,7 @@
 	ScLayer* layer = byID(layerID);
 	if (layer)
 	{
-		layer->markerColor = color;
+		layer->markerColor = std::move(color);
 		return true;
 	}
 	return false;

Modified: trunk/Scribus/scribus/scraction.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scraction.cpp
==============================================================================
--- trunk/Scribus/scribus/scraction.cpp	(original)
+++ trunk/Scribus/scribus/scraction.cpp	Wed May  2 22:17:14 2018
@@ -85,7 +85,7 @@
 {
 	m_actionType = ScrAction::Normal;
 	m_menuIndex = -1;
-	m_popupMenuAddedTo = NULL;
+	m_popupMenuAddedTo = nullptr;
 	m_savedKeySequence = QKeySequence("");
 	m_shortcutSaved = false;
 	m_fakeToggle = false;

Modified: trunk/Scribus/scribus/scribusdoc.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scribusdoc.cpp
==============================================================================
--- trunk/Scribus/scribus/scribusdoc.cpp	(original)
+++ trunk/Scribus/scribus/scribusdoc.cpp	Wed May  2 22:17:14 2018
@@ -202,7 +202,7 @@
 
 
 
-ScribusDoc::ScribusDoc() : UndoObject( tr("Document")), Observable<ScribusDoc>(NULL),
+ScribusDoc::ScribusDoc() : UndoObject( tr("Document")), Observable<ScribusDoc>(nullptr),
 	m_hasGUI(false),
 	m_docFilePermissions(QFileDevice::ReadOwner|QFileDevice::WriteOwner),
 	m_appPrefsData(PrefsManager::instance()->appPrefs),
@@ -2183,7 +2183,7 @@
 			{
 				if (is->get("MARK") == "new")
 				{
-					if (currItem == NULL)
+					if (currItem == nullptr)
 					{
 						qDebug() << "Wrong inItem in undo step for mark";
 						return;
@@ -2283,7 +2283,7 @@
 				else if (is->get("MARK") == "delNonUnique")
 				{
 					//used if deleting non-unique marks by MarksManager
-					eraseMark(mrk, true, NULL, true);
+					eraseMark(mrk, true, nullptr, true);
 				}
 				else
 				{
@@ -2623,7 +2623,7 @@
 {
 	assert(masterPageMode()==false);
 	ScPage* addedPage = new ScPage(m_docPrefsData.displayPrefs.scratch.left(), DocPages.count()*(m_docPrefsData.docSetupPrefs.pageHeight+m_docPrefsData.displayPrefs.scratch.bottom()+m_docPrefsData.displayPrefs.scratch.top())+m_docPrefsData.displayPrefs.scratch.top(), m_docPrefsData.docSetupPrefs.pageWidth, m_docPrefsData.docSetupPrefs.pageHeight);
-	assert(addedPage!=NULL);
+	assert(addedPage!=nullptr);
 	addedPage->setDocument(this);
 	addedPage->Margins.setTop(m_docPrefsData.docSetupPrefs.margins.top());
 	addedPage->Margins.setBottom(m_docPrefsData.docSetupPrefs.margins.bottom());
@@ -2633,7 +2633,7 @@
 	addedPage->setOrientation(m_docPrefsData.docSetupPrefs.pageOrientation);
 	addedPage->marginPreset = m_docPrefsData.docSetupPrefs.marginPreset;
 	DocPages.insert(pageIndex, addedPage);
-	assert(DocPages.at(pageIndex)!=NULL);
+	assert(DocPages.at(pageIndex)!=nullptr);
 	setCurrentPage(addedPage);
 	if (!masterPageName.isEmpty())
 		applyMasterPage(masterPageName, pageIndex);
@@ -9240,7 +9240,7 @@
 		{
 			ParagraphStyle newStyle;
 			//for notes frames apply style from master frame
-			if (currItem->isNoteFrame() && (currItem->asNoteFrame()->masterFrame() != NULL))
+			if (currItem->isNoteFrame() && (currItem->asNoteFrame()->masterFrame() != nullptr))
 			{
 				newStyle.setParent(currItem->asNoteFrame()->masterFrame()->itemText.defaultStyle().parent());
 				newStyle.applyStyle(currItem->asNoteFrame()->masterFrame()->currentStyle());
@@ -9265,7 +9265,7 @@
 			currItem->updatePolyClip();
 		if (currItem->isNoteFrame())
 			currItem->asNoteFrame()->updateNotesText();
-		else if (currItem->isTextFrame() && currItem->asTextFrame()->hasNoteFrame(NULL, true))
+		else if (currItem->isTextFrame() && currItem->asTextFrame()->hasNoteFrame(nullptr, true))
 			setNotesChanged(true);
 	}
 	if (activeTransaction)
@@ -9423,7 +9423,7 @@
 			currItem->updatePolyClip();
 		if (currItem->isNoteFrame())
 			currItem->asNoteFrame()->updateNotesText();
-		else if (currItem->isTextFrame() && currItem->asTextFrame()->hasNoteFrame(NULL, true))
+		else if (currItem->isTextFrame() && currItem->asTextFrame()->hasNoteFrame(nullptr, true))
 			setNotesChanged(true);
 		currItem->invalidateLayout();
 	}
@@ -13974,7 +13974,7 @@
 {
 	*GxM = -1;
 	*GyM = -1;
-	ScPage* page = (refPage == NULL) ? currentPage() : refPage;
+	ScPage* page = (refPage == nullptr) ? currentPage() : refPage;
 	QMap<double, uint> tmpGuidesSel;
 	Guides tmpGuides = page->guides.horizontals(GuideManagerCore::Standard);
 	Guides::iterator it;

Modified: trunk/Scribus/scribus/scstreamfilter.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scstreamfilter.cpp
==============================================================================
--- trunk/Scribus/scribus/scstreamfilter.cpp	(original)
+++ trunk/Scribus/scribus/scstreamfilter.cpp	Wed May  2 22:17:14 2018
@@ -14,17 +14,17 @@
 
 ScStreamFilter::ScStreamFilter(QDataStream* stream)
 {
-	assert(stream != NULL);
+	assert(stream != nullptr);
 	m_dataStream = stream;
-	m_filter     = NULL;
+	m_filter     = nullptr;
 	m_filterMode = FilterToStream;
 	m_writtenToStream = 0;
 }
 
 ScStreamFilter::ScStreamFilter(ScStreamFilter* filter)
 {
-	assert(filter != NULL);
-	m_dataStream = NULL;
+	assert(filter != nullptr);
+	m_dataStream = nullptr;
 	m_filter     = filter;
 	m_filterMode = FilterToFilter;
 	m_writtenToStream = 0;

Modified: trunk/Scribus/scribus/scstreamfilter_jpeg.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/scstreamfilter_jpeg.cpp
==============================================================================
--- trunk/Scribus/scribus/scstreamfilter_jpeg.cpp	(original)
+++ trunk/Scribus/scribus/scstreamfilter_jpeg.cpp	Wed May  2 22:17:14 2018
@@ -105,9 +105,9 @@
 	~ScJpegEncodeFilterData();
 };
 
-ScJpegEncodeFilterData::ScJpegEncodeFilterData() : cdest(NULL)
-{
-	row_pointer[0] = NULL;
+ScJpegEncodeFilterData::ScJpegEncodeFilterData() : cdest(nullptr)
+{
+	row_pointer[0] = nullptr;
 }
 
 ScJpegEncodeFilterData::~ScJpegEncodeFilterData()
@@ -122,7 +122,7 @@
 		            ScJpegEncodeFilter::Color color) : ScStreamFilter(stream), m_width(imgWidth), m_height(imgHeight),
 					m_quality(75), m_color(color)
 {
-	m_filterData = NULL;
+	m_filterData = nullptr;
 	m_openedFilter = false;
 }
 
@@ -130,7 +130,7 @@
 					ScJpegEncodeFilter::Color color) : ScStreamFilter(filter), m_width(imgWidth), m_height(imgHeight),
 					m_quality(75), m_color(color)
 {
-	m_filterData = NULL;
+	m_filterData = nullptr;
 	m_openedFilter = false;
 }
 
@@ -145,7 +145,7 @@
 {
 	if (m_filterData)
 		delete m_filterData;
-	m_filterData = NULL;
+	m_filterData = nullptr;
 }
 
 bool ScJpegEncodeFilter::openFilter (void)
@@ -156,7 +156,7 @@
 		return false;
 
 	m_filterData = new ScJpegEncodeFilterData();
-	if (m_filterData == NULL)
+	if (m_filterData == nullptr)
 		return false;
 
 	struct ScJpegErrorMgr jerr;
@@ -165,7 +165,7 @@
 	m_filterData->row_pointer[0] = 0;
 
 	m_filterData->cdest = new ScJpegDestinationMgr(this);
-	if (m_filterData->cdest == NULL)
+	if (m_filterData->cdest == nullptr)
 		return false;
 
 	bool success = false;
@@ -200,7 +200,7 @@
 	if (success)
 	{
 		m_filterData->row_pointer[0] = new uchar[m_filterData->cinfo.image_width * m_filterData->cinfo.input_components];
-		if (m_filterData->row_pointer[0] == NULL)
+		if (m_filterData->row_pointer[0] == nullptr)
 			success = false;
 	}
 	if (!success || !ScStreamFilter::openFilter())

Modified: trunk/Scribus/scribus/sctextstruct.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/sctextstruct.cpp
==============================================================================
--- trunk/Scribus/scribus/sctextstruct.cpp	(original)
+++ trunk/Scribus/scribus/sctextstruct.cpp	Wed May  2 22:17:14 2018
@@ -15,7 +15,7 @@
 {
 	if (doc->FrameItems.contains(m_object_id))
 		return doc->FrameItems[m_object_id];
-	return NULL;
+	return nullptr;
 }
 
 
@@ -23,8 +23,8 @@
 {
 	if (parstyle)
 		delete parstyle;
-	parstyle = NULL;
-	mark = NULL;
+	parstyle = nullptr;
+	mark = nullptr;
 }
 
 bool ScText::hasObject(ScribusDoc *doc) const
@@ -38,8 +38,8 @@
 {
 	if (this->ch == SpecialChars::OBJECT)
 	{
-		if (MRK == NULL)
-			return mark != NULL;
+		if (MRK == nullptr)
+			return mark != nullptr;
 		else
 			return mark == MRK;
 	}
@@ -63,7 +63,7 @@
 {
 	if ((embedded > 0) && (doc->FrameItems.contains(embedded)))
 		return doc->FrameItems[embedded];
-	return NULL;
+	return nullptr;
 }
 
 void ScText::setNewMark(Mark *mrk)

Modified: trunk/Scribus/scribus/sctextstruct.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/sctextstruct.h
==============================================================================
--- trunk/Scribus/scribus/sctextstruct.h	(original)
+++ trunk/Scribus/scribus/sctextstruct.h	Wed May  2 22:17:14 2018
@@ -134,12 +134,12 @@
 	QChar ch;
 	ScText() :
 		CharStyle(),
-		parstyle(NULL),
-		embedded(0), mark(NULL), ch() {}
+		parstyle(nullptr),
+		embedded(0), mark(nullptr), ch() {}
 	ScText(const ScText& other) :
 		CharStyle(other),
-		parstyle(NULL),
-		embedded(other.embedded), mark(NULL), ch(other.ch)
+		parstyle(nullptr),
+		embedded(other.embedded), mark(nullptr), ch(other.ch)
 	{
 		if (other.parstyle)
 			parstyle = new ParagraphStyle(*other.parstyle);
@@ -149,8 +149,8 @@
 	~ScText();
 
 	bool hasObject(ScribusDoc *doc) const;
-	//returns true if given MRK is found, if MRK is NULL then any mark returns true
-	bool hasMark(Mark * MRK = NULL) const;
+	//returns true if given MRK is found, if MRK is nullptr then any mark returns true
+	bool hasMark(Mark * MRK = nullptr) const;
 	QList<PageItem*> getGroupedItems(ScribusDoc *doc);
 	PageItem* getItem(ScribusDoc *doc);
 private:

Modified: trunk/Scribus/scribus/selection.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/selection.cpp
==============================================================================
--- trunk/Scribus/scribus/selection.cpp	(original)
+++ trunk/Scribus/scribus/selection.cpp	Wed May  2 22:17:14 2018
@@ -155,7 +155,7 @@
 	if (m_SelList.count() == 1)
 	{
 		QPointer<PageItem> pi=m_SelList.first();
-		//Quick check to see if the pointer is NULL, if its NULL, we should remove it from the list now
+		//Quick check to see if the pointer is nullptr, if its nullptr, we should remove it from the list now
 		if (pi.isNull())
 		{
 			m_SelList.removeAll(pi);
@@ -192,7 +192,7 @@
 
 bool Selection::addItem(PageItem *item, bool /*ignoreGUI*/)
 {
-	if (item==NULL)
+	if (item==nullptr)
 		return false;
 	bool listWasEmpty = m_SelList.isEmpty();
 	if (listWasEmpty || !m_SelList.contains(item))
@@ -212,7 +212,7 @@
 
 bool Selection::prependItem(PageItem *item, bool /*doEmit*/)
 {
-	if (item==NULL)
+	if (item==nullptr)
 		return false;
 	if (!m_SelList.contains(item))
 	{
@@ -236,13 +236,13 @@
 	if (!m_SelList.isEmpty() && index<m_SelList.count())
 	{
 		QPointer<PageItem> pi=m_SelList[index];
-		//If not NULL return it, otherwise remove from the list and return NULL
+		//If not nullptr return it, otherwise remove from the list and return nullptr
 		if (!pi.isNull())
 			return pi;
 //		SelectionList::Iterator it=m_SelList.at(index);
 		m_SelList.removeAt(index);
 	}
-	return NULL;
+	return nullptr;
 }
 
 QList<PageItem*> Selection::items() const
@@ -320,7 +320,7 @@
 			return item;
 		}
 	}
-	return NULL;
+	return nullptr;
 }
 
 QStringList Selection::getSelectedItemsByName() const

Modified: trunk/Scribus/scribus/text/itextsource.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/itextsource.h
==============================================================================
--- trunk/Scribus/scribus/text/itextsource.h	(original)
+++ trunk/Scribus/scribus/text/itextsource.h	Wed May  2 22:17:14 2018
@@ -49,17 +49,17 @@
 	virtual bool hasExpansionPoint(int pos) const = 0;
 	virtual ExpansionPoint expansionPoint(int pos) const = 0;
 	
-	virtual const ITextSource* parent() const { return NULL; }
+	virtual const ITextSource* parent() const { return nullptr; }
 	virtual int parentPos() const { return 0; }
 	
 	const ITextSource* original() const
     {
-		return parent() == NULL? this : parent()->original();
+		return parent() == nullptr? this : parent()->original();
 	}
 	
 	const int originalStartPos() const
 	{
-		return parent() == NULL? 0 : parent()->parent() == NULL? parentPos() : parent()->originalStartPos();
+		return parent() == nullptr? 0 : parent()->parent() == nullptr? parentPos() : parent()->originalStartPos();
     }
 };
 

Modified: trunk/Scribus/scribus/text/screenpainter.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/screenpainter.cpp
==============================================================================
--- trunk/Scribus/scribus/text/screenpainter.cpp	(original)
+++ trunk/Scribus/scribus/text/screenpainter.cpp	Wed May  2 22:17:14 2018
@@ -23,7 +23,7 @@
 	, m_item(item)
 	, m_fillColor("", -1)
 	, m_strokeColor("", -1)
-	, m_cairoFace(NULL)
+	, m_cairoFace(nullptr)
 	, m_faceIndex(-10) // ScFace::faceIndex() defaults to -1, we need a different value
 {
 	m_painter->save();
@@ -39,7 +39,7 @@
 
 ScreenPainter::~ScreenPainter()
 {
-	if (m_cairoFace != NULL)
+	if (m_cairoFace != nullptr)
 		cairo_font_face_destroy(m_cairoFace);
 	m_painter->restore();
 }
@@ -61,7 +61,7 @@
 		cairo_set_source_rgba(cr, r, g, b, m_painter->brushOpacity());
 		m_painter->setRasterOp(m_painter->blendModeFill());
 
-		if (m_fontPath != font().fontFilePath() || m_faceIndex != font().faceIndex() || m_cairoFace == NULL)
+		if (m_fontPath != font().fontFilePath() || m_faceIndex != font().faceIndex() || m_cairoFace == nullptr)
 		{
 			m_fontPath = font().fontFilePath();
 			m_faceIndex = font().faceIndex();
@@ -70,10 +70,10 @@
 			// crazy values, breaking any subsequent call to the layout
 			// painter.  FIXME: drop the FontConfig dependency here once
 			// Scribus font handling code is made sane!
-			FcPattern *pattern = FcPatternBuild(NULL,
+			FcPattern *pattern = FcPatternBuild(nullptr,
 							    FC_FILE, FcTypeString, QFile::encodeName(font().fontFilePath()).data(),
 							    FC_INDEX, FcTypeInteger, font().faceIndex(),
-							    NULL);
+								nullptr);
 			m_cairoFace = cairo_ft_font_face_create_for_pattern(pattern);
 			FcPatternDestroy(pattern);
 		}

Modified: trunk/Scribus/scribus/text/sctext_shared.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/sctext_shared.cpp
==============================================================================
--- trunk/Scribus/scribus/text/sctext_shared.cpp	(original)
+++ trunk/Scribus/scribus/text/sctext_shared.cpp	Wed May  2 22:17:14 2018
@@ -18,7 +18,7 @@
 
 ScText_Shared::ScText_Shared(const StyleContext* pstyles) : QList<ScText*>(), 
 	defaultStyle(), 
-	pstyleContext(NULL),
+	pstyleContext(nullptr),
 	refs(1), len(0), cursorPosition(0), trailingStyle()
 {
 	pstyleContext.setDefaultStyle( & defaultStyle );
@@ -128,7 +128,7 @@
 	// we are done here but will do a sanity check:
 	// assert that all chars point to the following parstyle
 	QListIterator<ScText*> it( *this );
-	const StyleContext* lastContext = NULL;
+	const StyleContext* lastContext = nullptr;
 	while ( it.hasNext() ) {
 		ScText* elem = it.next();
 		assert( elem );
@@ -143,9 +143,9 @@
 			{
 				assert( lastContext == elem->parstyle->charStyleContext() );
 			}
-			lastContext = NULL;
+			lastContext = nullptr;
 		}
-		else if (lastContext == NULL)
+		else if (lastContext == nullptr)
 		{
 			lastContext = elem->context();
 		}

Modified: trunk/Scribus/scribus/text/shapedtext.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/shapedtext.cpp
==============================================================================
--- trunk/Scribus/scribus/text/shapedtext.cpp	(original)
+++ trunk/Scribus/scribus/text/shapedtext.cpp	Wed May  2 22:17:14 2018
@@ -78,11 +78,11 @@
 
 
 
-ShapedText ShapedText::Invalid = ShapedText(NULL);
+ShapedText ShapedText::Invalid = ShapedText(nullptr);
 
 bool ShapedText::isValid() const
 {
-	return p_impl != NULL && p_impl->m_source != NULL;
+	return p_impl != nullptr && p_impl->m_source != nullptr;
 }
 
 

Modified: trunk/Scribus/scribus/text/shapedtextcache.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/shapedtextcache.cpp
==============================================================================
--- trunk/Scribus/scribus/text/shapedtextcache.cpp	(original)
+++ trunk/Scribus/scribus/text/shapedtextcache.cpp	Wed May  2 22:17:14 2018
@@ -18,7 +18,7 @@
 	
 public:
 	
-	// check if all ShapedText in the cache for this range are valid, i.e. source() != NULL
+	// check if all ShapedText in the cache for this range are valid, i.e. source() != nullptr
 	bool contains(int charPos, uint len) const
 	{
 		int last = charPos + len - 1;
@@ -52,7 +52,7 @@
 		while (result.lastChar() < last)
 		{
 			ShapedText st = m_cache(result.lastChar() + 1);
-			if (st.source() == NULL || !result.canCombine(st))
+			if (st.source() == nullptr || !result.canCombine(st))
 				return ShapedText::Invalid;
 			result.combine(st);
 		}
@@ -70,7 +70,7 @@
 	
 	void clear(int charPos, uint len)
 	{
-		put(ShapedText(NULL, charPos, charPos + len - 1));
+		put(ShapedText(nullptr, charPos, charPos + len - 1));
 	}
 
 	

Modified: trunk/Scribus/scribus/text/shapedtextfeed.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/shapedtextfeed.cpp
==============================================================================
--- trunk/Scribus/scribus/text/shapedtextfeed.cpp	(original)
+++ trunk/Scribus/scribus/text/shapedtextfeed.cpp	Wed May  2 22:17:14 2018
@@ -51,7 +51,7 @@
 
 ShapedText ShapedTextFeed::getMore(int fromChar, int toChar)
 {
-	if (m_cache != NULL)
+	if (m_cache != nullptr)
 	{
 		int len = toChar - fromChar;
 		if (!m_cache->contains(fromChar, len))

Modified: trunk/Scribus/scribus/text/shapedtextfeed.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/shapedtextfeed.h
==============================================================================
--- trunk/Scribus/scribus/text/shapedtextfeed.h	(original)
+++ trunk/Scribus/scribus/text/shapedtextfeed.h	Wed May  2 22:17:14 2018
@@ -32,7 +32,7 @@
 	int m_endChar;
 	
 public:
-	ShapedTextFeed(ITextSource* source, int startChar, ITextContext* context, IShapedTextCache* cache = NULL);
+	ShapedTextFeed(ITextSource* source, int startChar, ITextContext* context, IShapedTextCache* cache = nullptr);
 	
 	bool haveMoreText(int glyphPos, QList<GlyphCluster>& glyphs);
 	

Modified: trunk/Scribus/scribus/text/storytext.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/storytext.h
==============================================================================
--- trunk/Scribus/scribus/text/storytext.h	(original)
+++ trunk/Scribus/scribus/text/storytext.h	Wed May  2 22:17:14 2018
@@ -162,7 +162,7 @@
 
 	bool hasObject(int pos) const;
  	PageItem* getItem(int pos) const; // deprecated
-    bool hasMark(int pos, Mark* mrk = NULL) const;
+	bool hasMark(int pos, Mark* mrk = nullptr) const;
 	Mark *mark(int pos) const;
     void replaceMark(int pos, Mark* mrk);
 	void applyMarkCharstyle(Mark* mrk, CharStyle& currStyle) const;

Modified: trunk/Scribus/scribus/text/textcontext.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/textcontext.cpp
==============================================================================
--- trunk/Scribus/scribus/text/textcontext.cpp	(original)
+++ trunk/Scribus/scribus/text/textcontext.cpp	Wed May  2 22:17:14 2018
@@ -89,7 +89,7 @@
 		case ExpansionPoint::MarkCE:
 			{
 				Mark* mark = expansion.getMark();
-				if (mark != NULL)
+				if (mark != nullptr)
 				{
 					mark->OwnPage = m_frame->OwnPage;
 					//itemPtr and itemName set to this frame only if mark type is different than MARK2ItemType
@@ -110,7 +110,7 @@
 
 
 						TextNote* note = mark->getNotePtr();
-						if (note == NULL)
+						if (note == nullptr)
 							return QString();
 
 					}

Modified: trunk/Scribus/scribus/text/textlayout.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/textlayout.cpp
==============================================================================
--- trunk/Scribus/scribus/text/textlayout.cpp	(original)
+++ trunk/Scribus/scribus/text/textlayout.cpp	Wed May  2 22:17:14 2018
@@ -66,7 +66,7 @@
 		count += box->boxes().count();
 	}
 	assert(false);
-	return NULL;
+	return nullptr;
 }
 
 const Box* TextLayout::box() const
@@ -378,7 +378,7 @@
 			if (column->boxes().count() > 0)
 			{
 				Box* line = column->boxes().last();
-				Box* glyph = line->boxes().empty() ? NULL : line->boxes().last();
+				Box* glyph = line->boxes().empty() ? nullptr : line->boxes().last();
 				QChar ch = story()->text(line->lastChar());
 				if (ch == SpecialChars::PARSEP || ch == SpecialChars::LINEBREAK)
 				{
@@ -393,7 +393,7 @@
 				else
 				{
 					// draw the cursor at the end of last line.
-					if (isRTL || glyph == NULL)
+					if (isRTL || glyph == nullptr)
 						x = line->x();
 					else
 						x = line->x() + glyph->x() + glyph->width();

Modified: trunk/Scribus/scribus/text/textshaper.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/text/textshaper.cpp
==============================================================================
--- trunk/Scribus/scribus/text/textshaper.cpp	(original)
+++ trunk/Scribus/scribus/text/textshaper.cpp	Wed May  2 22:17:14 2018
@@ -25,7 +25,7 @@
 { }
 
 TextShaper::TextShaper(ITextSource &story, int firstChar)
-	: m_context(NULL),
+	: m_context(nullptr),
 	m_contextNeeded(false),
 	m_story(story),
 	m_firstChar(firstChar),
@@ -53,7 +53,7 @@
 	if (style.direction() == ParagraphStyle::RTL)
 		parLevel = UBIDI_RTL;
 
-	ubidi_setPara(obj, (const UChar*) m_text.utf16(), m_text.length(), parLevel, NULL, &err);
+	ubidi_setPara(obj, (const UChar*) m_text.utf16(), m_text.length(), parLevel, nullptr, &err);
 	if (U_SUCCESS(err))
 	{
 		int32_t count = ubidi_countRuns(obj, &err);
@@ -188,7 +188,7 @@
 		if (m_story.hasExpansionPoint(i))
 		{
 			m_contextNeeded = true;
-			if (m_context != NULL)
+			if (m_context != nullptr)
 			{
 				str = m_context->expand(m_story.expansionPoint(i));
 				if (str.isEmpty())
@@ -332,7 +332,7 @@
 
 		const ScFace &scFace = style.font();
 		hb_font_t *hbFont = reinterpret_cast<hb_font_t*>(scFace.hbFont());
-		if (hbFont == NULL)
+		if (hbFont == nullptr)
 			continue;
 
 		hb_font_set_scale(hbFont, style.fontSize(), style.fontSize());
@@ -380,8 +380,8 @@
 		hb_shape_full(hbFont, hbBuffer, hbFeatures.data(), hbFeatures.length(), shapers);
 
 		unsigned int count = hb_buffer_get_length(hbBuffer);
-		hb_glyph_info_t *glyphs = hb_buffer_get_glyph_infos(hbBuffer, NULL);
-		hb_glyph_position_t *positions = hb_buffer_get_glyph_positions(hbBuffer, NULL);
+		hb_glyph_info_t *glyphs = hb_buffer_get_glyph_infos(hbBuffer, nullptr);
+		hb_glyph_position_t *positions = hb_buffer_get_glyph_positions(hbBuffer, nullptr);
 
 		result.glyphs().reserve(result.glyphs().size() + count);
 		for (size_t i = 0; i < count; )
@@ -502,14 +502,14 @@
 				if (m_story.hasObject(firstChar))
 				{
 					m_contextNeeded = true;
-					if (m_context != NULL)
+					if (m_context != nullptr)
 						gl.xadvance = m_context->getVisualBoundingBox(m_story.object(firstChar)).width();
 				}
 
 				if ((effects & ScStyle_Superscript) || (effects & ScStyle_Subscript))
 				{
 					m_contextNeeded = true;
-					if (m_context != NULL)
+					if (m_context != nullptr)
 					{
 						double scale;
 						double asce = style.font().ascent(style.fontSize() / 10.0);
@@ -532,7 +532,7 @@
 				if (smallCaps.contains(firstCluster))
 				{
 					m_contextNeeded = true;
-					if (m_context != NULL)
+					if (m_context != nullptr)
 					{
 						
 						double smallcapsScale = m_context->typographicPrefs().valueSmallCaps / 100.0;

Modified: trunk/Scribus/scribus/tocgenerator.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/tocgenerator.cpp
==============================================================================
--- trunk/Scribus/scribus/tocgenerator.cpp	(original)
+++ trunk/Scribus/scribus/tocgenerator.cpp	Wed May  2 22:17:14 2018
@@ -44,12 +44,12 @@
 
 PageItem* TOCGenerator::findTargetFrame(const QString &targetFrameName)
 {
-	PageItem* targetFrame=NULL;
-	if (m_doc != NULL)
+	PageItem* targetFrame=nullptr;
+	if (m_doc != nullptr)
 	{
 		for (int d = 0; d < m_doc->DocItems.count(); ++d)
 		{
-			if (m_doc->DocItems.at(d) != NULL)
+			if (m_doc->DocItems.at(d) != nullptr)
 			{
 				if (m_doc->DocItems.at(d)->itemType()==PageItem::TextFrame && m_doc->DocItems.at(d)->itemName()==targetFrameName)
 				{
@@ -64,20 +64,20 @@
 
 void TOCGenerator::generateDefault()
 {
-	if (m_doc == NULL)
+	if (m_doc == nullptr)
 		return;
 	Q_ASSERT(!m_doc->masterPageMode());
 	for(ToCSetupVector::Iterator tocSetupIt = m_doc->tocSetups().begin(); tocSetupIt != m_doc->tocSetups().end(); ++tocSetupIt )
 	{
 		PageItem* tocFrame = findTargetFrame(tocSetupIt->frameName);
-		if (tocFrame == NULL)
+		if (tocFrame == nullptr)
 			continue;
 
 		PageItem *currentDocItem;
 		QMap<QString, QString> tocMap;
 
 		uint *pageCounter = new uint[m_doc->DocPages.count()];
-		if (pageCounter == NULL)
+		if (pageCounter == nullptr)
 			return;
 		uint pageNumberWidth = QString("%1").arg(m_doc->DocPages.count()).length();
 		for (int i = 0; i < m_doc->DocPages.count(); ++i)
@@ -87,7 +87,7 @@
 		while (itemIter.next())
 		{
 			currentDocItem = itemIter.current();
-			if (currentDocItem == NULL)
+			if (currentDocItem == nullptr)
 				continue;
 			//Item not on a page, continue
 			if (currentDocItem->OwnPage == -1)

Modified: trunk/Scribus/scribus/ui/sctablewidget.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/ui/sctablewidget.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/sctablewidget.cpp	(original)
+++ trunk/Scribus/scribus/ui/sctablewidget.cpp	Wed May  2 22:17:14 2018
@@ -99,7 +99,7 @@
 {
 	QTableWidget::removeCellWidget(row, column);
 	QHash<QWidget*, QPair<int, int> >::const_iterator i = widgetPositions.constBegin();
-	QWidget* t=NULL;
+	QWidget* t=nullptr;
 	while (i != widgetPositions.constEnd())
 	{
 		if (i.value().first==row && i.value().second==column)
@@ -109,6 +109,6 @@
 		}
 		++i;
 	}
-	if (t!=NULL)
+	if (t!=nullptr)
 		widgetPositions.remove(t);
 }

Modified: trunk/Scribus/scribus/undomanager.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/undomanager.h
==============================================================================
--- trunk/Scribus/scribus/undomanager.h	(original)
+++ trunk/Scribus/scribus/undomanager.h	Wed May  2 22:17:14 2018
@@ -58,7 +58,7 @@
 	QString  description;
 	QPixmap *actionPixmap;
 
-	TransactionSettings(void) { targetPixmap = actionPixmap = NULL; }  
+	TransactionSettings(void) { targetPixmap = actionPixmap = nullptr; }
 };
 
 /**

Modified: trunk/Scribus/scribus/util.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/util.h
==============================================================================
--- trunk/Scribus/scribus/util.h	(original)
+++ trunk/Scribus/scribus/util.h	Wed May  2 22:17:14 2018
@@ -96,7 +96,7 @@
 */
 int SCRIBUS_API System(const QString exename, const QStringList & args,
 					   const QString fileStdErr = "", const QString fileStdOut = "",
-					   bool* cancel = NULL);
+					   bool* cancel = nullptr);
 
 /*!
  \fn QString checkFileExtension(const QString &currName, const QString &extension)

Modified: trunk/Scribus/scribus/util_color.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22518&path=/trunk/Scribus/scribus/util_color.cpp
==============================================================================
--- trunk/Scribus/scribus/util_color.cpp	(original)
+++ trunk/Scribus/scribus/util_color.cpp	Wed May  2 22:17:14 2018
@@ -812,7 +812,7 @@
 						}
 						else if (pg.tagName() == "Gradient")
 						{
-							if (dialogGradients != NULL)
+							if (dialogGradients != nullptr)
 							{
 								VGradient gra = VGradient(VGradient::linear);
 								gra.clearStops();
@@ -830,7 +830,7 @@
 									else
 									{
 										const ScColor& col = EditColors[name];
-										color = ScColorEngine::getShadeColorProof(col, NULL, shade);
+										color = ScColorEngine::getShadeColorProof(col, nullptr, shade);
 									}
 									gra.addStop(color, ramp, 0.5, opa, name, shade);
 									grad = grad.nextSibling();




More information about the scribus-commit mailing list