Browse Source

TQt4 port kdegraphics

This enables compilation under both Qt3 and Qt4


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1237557 283d02a7-25f6-0310-bc7c-ecb5cbfe19
tpearson 7 years ago
parent
commit
e69e8b1d09
100 changed files with 948 additions and 916 deletions
  1. 25
    25
      kamera/kcontrol/kamera.cpp
  2. 2
    1
      kamera/kcontrol/kamera.h
  3. 18
    18
      kamera/kcontrol/kameraconfigdialog.cpp
  4. 3
    2
      kamera/kcontrol/kameraconfigdialog.h
  5. 14
    14
      kamera/kcontrol/kameradevice.cpp
  6. 4
    2
      kamera/kcontrol/kameradevice.h
  7. 8
    8
      kamera/kioslave/kamera.cpp
  8. 8
    8
      kcoloredit/colorselector.cpp
  9. 2
    1
      kcoloredit/colorselector.h
  10. 2
    2
      kcoloredit/editablestreamhistory.h
  11. 8
    8
      kcoloredit/gradientselection.cpp
  12. 2
    1
      kcoloredit/gradientselection.h
  13. 1
    1
      kcoloredit/imageselection.cpp
  14. 2
    1
      kcoloredit/imageselection.h
  15. 2
    2
      kcoloredit/kcolorchooser.cpp
  16. 15
    15
      kcoloredit/kcoloredit.cpp
  17. 3
    2
      kcoloredit/kcoloredit.h
  18. 9
    9
      kcoloredit/kcoloreditdoc.cpp
  19. 4
    3
      kcoloredit/kcoloreditdoc.h
  20. 10
    10
      kcoloredit/kcoloreditview.cpp
  21. 4
    3
      kcoloredit/kcoloreditview.h
  22. 22
    22
      kcoloredit/kxycolorselector.cpp
  23. 2
    1
      kcoloredit/kxycolorselector.h
  24. 21
    21
      kcoloredit/kzcolorselector.cpp
  25. 2
    1
      kcoloredit/kzcolorselector.h
  26. 3
    3
      kcoloredit/loadpalettedlg.cpp
  27. 2
    1
      kcoloredit/loadpalettedlg.h
  28. 4
    4
      kcoloredit/palette.cpp
  29. 3
    3
      kcoloredit/paletteview.cpp
  30. 3
    2
      kcoloredit/paletteview.h
  31. 12
    12
      kcoloredit/paletteviewscrolledarea.cpp
  32. 5
    4
      kcoloredit/paletteviewscrolledarea.h
  33. 5
    5
      kcoloredit/texteditselection.cpp
  34. 3
    2
      kcoloredit/texteditselection.h
  35. 1
    1
      kcoloredit/textselection.cpp
  36. 5
    5
      kdvi/TeXFont.h
  37. 8
    8
      kdvi/TeXFontDefinition.cpp
  38. 7
    7
      kdvi/TeXFontDefinition.h
  39. 32
    32
      kdvi/TeXFont_PFB.cpp
  40. 3
    3
      kdvi/TeXFont_PFB.h
  41. 53
    53
      kdvi/TeXFont_PK.cpp
  42. 2
    2
      kdvi/TeXFont_PK.h
  43. 12
    12
      kdvi/TeXFont_TFM.cpp
  44. 5
    5
      kdvi/TeXFont_TFM.h
  45. 14
    14
      kdvi/bigEndianByteReader.cpp
  46. 8
    8
      kdvi/bigEndianByteReader.h
  47. 22
    22
      kdvi/dviFile.cpp
  48. 14
    14
      kdvi/dviFile.h
  49. 1
    0
      kdvi/dviPageCache.h
  50. 55
    55
      kdvi/dviRenderer.cpp
  51. 14
    13
      kdvi/dviRenderer.h
  52. 13
    13
      kdvi/dviRenderer_draw.cpp
  53. 37
    37
      kdvi/dviRenderer_export.cpp
  54. 66
    66
      kdvi/dviRenderer_prescan.cpp
  55. 7
    7
      kdvi/dviWidget.cpp
  56. 2
    1
      kdvi/dviWidget.h
  57. 2
    2
      kdvi/dvisourcesplitter.cpp
  58. 2
    2
      kdvi/dvisourcesplitter.h
  59. BIN
      kdvi/examples/dvistd0.dvi
  60. 2
    2
      kdvi/fontEncoding.cpp
  61. 2
    2
      kdvi/fontEncoding.h
  62. 1
    1
      kdvi/fontEncodingPool.cpp
  63. 11
    11
      kdvi/fontMap.cpp
  64. 5
    5
      kdvi/fontMap.h
  65. 41
    41
      kdvi/fontpool.cpp
  66. 6
    5
      kdvi/fontpool.h
  67. 7
    7
      kdvi/fontprogress.cpp
  68. 3
    2
      kdvi/fontprogress.h
  69. 3
    3
      kdvi/glyph.h
  70. 16
    16
      kdvi/infodialog.cpp
  71. 2
    1
      kdvi/infodialog.h
  72. 13
    13
      kdvi/kdvi_multipage.cpp
  73. 2
    1
      kdvi/kdvi_multipage.h
  74. 3
    3
      kdvi/main.cpp
  75. 3
    3
      kdvi/optionDialogFontsWidget.cpp
  76. 2
    1
      kdvi/optionDialogFontsWidget.h
  77. 7
    7
      kdvi/optionDialogFontsWidget_base.ui
  78. 3
    3
      kdvi/optionDialogSpecialWidget.cpp
  79. 2
    1
      kdvi/optionDialogSpecialWidget.h
  80. 10
    10
      kdvi/optionDialogSpecialWidget_base.ui
  81. 3
    3
      kdvi/prebookmark.h
  82. 33
    33
      kdvi/psgs.cpp
  83. 2
    1
      kdvi/psgs.h
  84. 3
    3
      kdvi/psheader.txt
  85. 1
    0
      kdvi/renderedDviPagePixmap.h
  86. 30
    30
      kdvi/special.cpp
  87. 8
    8
      kdvi/vf.cpp
  88. 7
    7
      kfax/faxinput.cpp
  89. 58
    58
      kfax/kfax.cpp
  90. 3
    2
      kfax/kfax.h
  91. 2
    2
      kfax/kfax_printsettings.cpp
  92. 5
    4
      kfax/kfax_printsettings.h
  93. 9
    9
      kfax/options.cpp
  94. 4
    3
      kfax/options.h
  95. 2
    2
      kfaxview/faxmultipage.cpp
  96. 2
    1
      kfaxview/faxmultipage.h
  97. 10
    10
      kfaxview/faxrenderer.cpp
  98. 2
    1
      kfaxview/faxrenderer.h
  99. 2
    2
      kfaxview/libkfaximage/faxexpand.h
  100. 0
    0
      kfaxview/libkfaximage/kfaximage.cpp

+ 25
- 25
kamera/kcontrol/kamera.cpp View File

@@ -48,8 +48,8 @@ K_EXPORT_COMPONENT_FACTORY( kcm_kamera, KKameraConfigFactory( "kcmkamera" ) )
48 48
 
49 49
 KKameraConfig *KKameraConfig::m_instance = NULL;
50 50
 
51
-KKameraConfig::KKameraConfig(TQWidget *parent, const char *name, const TQStringList &)
52
-	: KCModule(KKameraConfigFactory::instance(), parent, name)
51
+KKameraConfig::KKameraConfig(TQWidget *tqparent, const char *name, const TQStringList &)
52
+	: KCModule(KKameraConfigFactory::instance(), tqparent, name)
53 53
 {
54 54
 	m_devicePopup = new KPopupMenu(this);
55 55
 	m_actions = new KActionCollection(this);
@@ -96,7 +96,7 @@ void KKameraConfig::displayGPSuccessDialogue(void)
96 96
 	// set the kcontrol module buttons
97 97
 	setButtons(Help | Apply | Cancel | Ok);
98 98
 
99
-	// create a layout with two vertical boxes
99
+	// create a tqlayout with two vertical boxes
100 100
 	TQVBoxLayout *topLayout = new TQVBoxLayout(this, 0, 0);
101 101
 	topLayout->setAutoAdd(true);
102 102
 	
@@ -113,29 +113,29 @@ void KKameraConfig::displayGPSuccessDialogue(void)
113 113
 	connect(m_deviceSel, TQT_SIGNAL(selectionChanged(TQIconViewItem *)),
114 114
 		TQT_SLOT(slot_deviceSelected(TQIconViewItem *)));
115 115
 
116
-	m_deviceSel->setSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Expanding));
116
+	m_deviceSel->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Expanding));
117 117
 	
118 118
 	// create actions
119 119
 	KAction *act;
120 120
 	
121
-	act = new KAction(i18n("Add"), "camera", 0, this, TQT_SLOT(slot_addCamera()), m_actions, "camera_add");
121
+	act = new KAction(i18n("Add"), "camera", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_addCamera()), m_actions, "camera_add");
122 122
 	act->setWhatsThis(i18n("Click this button to add a new camera."));
123 123
 	act->plug(m_toolbar);
124 124
 	m_toolbar->insertLineSeparator();
125
-	act = new KAction(i18n("Test"), "camera_test", 0, this, TQT_SLOT(slot_testCamera()), m_actions, "camera_test");
125
+	act = new KAction(i18n("Test"), "camera_test", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_testCamera()), m_actions, "camera_test");
126 126
 	act->setWhatsThis(i18n("Click this button to remove the selected camera from the list."));
127 127
 	act->plug(m_toolbar);
128
-	act = new KAction(i18n("Remove"), "edittrash", 0, this, TQT_SLOT(slot_removeCamera()), m_actions, "camera_remove");
128
+	act = new KAction(i18n("Remove"), "edittrash", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_removeCamera()), m_actions, "camera_remove");
129 129
 	act->setWhatsThis(i18n("Click this button to remove the selected camera from the list."));
130 130
 	act->plug(m_toolbar);
131
-	act = new KAction(i18n("Configure..."), "configure", 0, this, TQT_SLOT(slot_configureCamera()), m_actions, "camera_configure");
131
+	act = new KAction(i18n("Configure..."), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_configureCamera()), m_actions, "camera_configure");
132 132
 	act->setWhatsThis(i18n("Click this button to change the configuration of the selected camera.<br><br>The availability of this feature and the contents of the Configuration dialog depend on the camera model."));
133 133
 	act->plug(m_toolbar);
134
-	act = new KAction(i18n("Information"), "hwinfo", 0, this, TQT_SLOT(slot_cameraSummary()), m_actions, "camera_summary");
134
+	act = new KAction(i18n("Information"), "hwinfo", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_cameraSummary()), m_actions, "camera_summary");
135 135
 	act->setWhatsThis(i18n("Click this button to view a summary of the current status of the selected camera.<br><br>The availability of this feature and the contents of the Configuration dialog depend on the camera model."));
136 136
 	act->plug(m_toolbar);
137 137
 	m_toolbar->insertLineSeparator();
138
-	act = new KAction(i18n("Cancel"), "stop", 0, this, TQT_SLOT(slot_cancelOperation()), m_actions, "camera_cancel");
138
+	act = new KAction(i18n("Cancel"), "stop", 0, TQT_TQOBJECT(this), TQT_SLOT(slot_cancelOperation()), m_actions, "camera_cancel");
139 139
 	act->setWhatsThis(i18n("Click this button to cancel the current camera operation."));
140 140
 	act->setEnabled(false);
141 141
 	act->plug(m_toolbar);
@@ -184,7 +184,7 @@ void KKameraConfig::load(bool useDefaults )
184 184
 	for (it = groupList.begin(); it != groupList.end(); it++) {
185 185
 		if (*it != "<default>")	{
186 186
 			m_config->setGroup(*it);
187
-			if (m_config->readEntry("Path").contains("usb:"))
187
+			if (m_config->readEntry("Path").tqcontains("usb:"))
188 188
 				continue;
189 189
 
190 190
 			kcamera = new KCamera(*it,m_config->readEntry("Path"));
@@ -218,7 +218,7 @@ void KKameraConfig::load(bool useDefaults )
218 218
 		if (!strcmp(value,"usb:"))
219 219
 			names[model] = value;
220 220
 	}
221
-	if (ports.contains("usb:") && names[ports["usb:"]]!="usb:")
221
+	if (ports.tqcontains("usb:") && names[ports["usb:"]]!="usb:")
222 222
 		ports.remove("usb:");
223 223
 
224 224
 	TQMap<TQString,TQString>::iterator portit;
@@ -256,7 +256,7 @@ void KKameraConfig::afterCameraOperation(void)
256 256
 
257 257
 	// if we're regaining control after a Cancel...
258 258
 	if (m_cancelPending) {
259
-		qApp->restoreOverrideCursor();
259
+		tqApp->restoreOverrideCursor();
260 260
 		m_cancelPending = false;
261 261
 	}
262 262
 	
@@ -268,23 +268,23 @@ void KKameraConfig::afterCameraOperation(void)
268 268
 TQString KKameraConfig::suggestName(const TQString &name)
269 269
 {
270 270
 	TQString new_name = name;
271
-	new_name.replace("/", ""); // we cannot have a slash in a URI's host
271
+	new_name.tqreplace("/", ""); // we cannot have a slash in a URI's host
272 272
 
273
-	if (!m_devices.contains(new_name)) return new_name;
273
+	if (!m_devices.tqcontains(new_name)) return new_name;
274 274
 	
275 275
 	// try new names with a number appended until we find a free one
276 276
 	int i = 1;
277 277
 	while (i++ < 0xffff) {
278 278
 		new_name = name + " (" + TQString::number(i) + ")";
279
-		if (!m_devices.contains(new_name)) return new_name;
279
+		if (!m_devices.tqcontains(new_name)) return new_name;
280 280
 	}
281 281
 
282
-	return TQString::null;
282
+	return TQString();
283 283
 }
284 284
 
285 285
 void KKameraConfig::slot_addCamera()
286 286
 {
287
-	KCamera *m_device = new KCamera(TQString::null,TQString::null);
287
+	KCamera *m_device = new KCamera(TQString(),TQString());
288 288
 	connect(m_device, TQT_SIGNAL(error(const TQString &)), TQT_SLOT(slot_error(const TQString &)));
289 289
 	connect(m_device, TQT_SIGNAL(error(const TQString &, const TQString &)), TQT_SLOT(slot_error(const TQString &, const TQString &)));
290 290
 	KameraDeviceSelectDialog dialog(this, m_device);
@@ -302,7 +302,7 @@ void KKameraConfig::slot_addCamera()
302 302
 void KKameraConfig::slot_removeCamera()
303 303
 {
304 304
 	TQString name = m_deviceSel->currentItem()->text();
305
-	if (m_devices.contains(name)) {
305
+	if (m_devices.tqcontains(name)) {
306 306
 		KCamera *m_device = m_devices[name];
307 307
 		m_devices.remove(name);
308 308
 		delete m_device;
@@ -317,7 +317,7 @@ void KKameraConfig::slot_testCamera()
317 317
 	beforeCameraOperation();
318 318
 
319 319
 	TQString name = m_deviceSel->currentItem()->text();
320
-	if (m_devices.contains(name)) {
320
+	if (m_devices.tqcontains(name)) {
321 321
 		KCamera *m_device = m_devices[name];
322 322
 		if (m_device->test())
323 323
 			KMessageBox::information(this, i18n("Camera test was successful."));
@@ -329,7 +329,7 @@ void KKameraConfig::slot_testCamera()
329 329
 void KKameraConfig::slot_configureCamera()
330 330
 {
331 331
 	TQString name = m_deviceSel->currentItem()->text();
332
-	if (m_devices.contains(name)) {
332
+	if (m_devices.tqcontains(name)) {
333 333
 		KCamera *m_device = m_devices[name];
334 334
 		m_device->configure();
335 335
 	}
@@ -339,7 +339,7 @@ void KKameraConfig::slot_cameraSummary()
339 339
 {
340 340
 	TQString summary;
341 341
 	TQString name = m_deviceSel->currentItem()->text();
342
-	if (m_devices.contains(name)) {
342
+	if (m_devices.tqcontains(name)) {
343 343
 		KCamera *m_device = m_devices[name];
344 344
 		summary = m_device->summary();
345 345
 		if (!summary.isNull()) {
@@ -354,7 +354,7 @@ void KKameraConfig::slot_cancelOperation()
354 354
 	// Prevent the user from keeping clicking Cancel
355 355
 	m_actions->action("camera_cancel")->setEnabled(false);
356 356
 	// and indicate that the click on Cancel did have some effect
357
-	qApp->setOverrideCursor(Qt::WaitCursor);
357
+	tqApp->setOverrideCursor(TQt::WaitCursor);
358 358
 }
359 359
 
360 360
 void KKameraConfig::slot_deviceMenu(TQIconViewItem *item, const TQPoint &point)
@@ -381,7 +381,7 @@ void KKameraConfig::cbGPIdle(GPContext * /*context*/, void * /*data*/)
381 381
 {
382 382
 	/*KKameraConfig *self( reinterpret_cast<KKameraConfig*>(data) );*/
383 383
 
384
-	qApp->processEvents();
384
+	tqApp->processEvents();
385 385
 }
386 386
 
387 387
 GPContextFeedback KKameraConfig::cbGPCancel(GPContext * /*context*/, void *data)
@@ -390,7 +390,7 @@ GPContextFeedback KKameraConfig::cbGPCancel(GPContext * /*context*/, void *data)
390 390
 
391 391
 	// Since in practice no camera driver supports idle callbacks yet,
392 392
 	// we'll use the cancel callback as opportunity to process events
393
-	qApp->processEvents();
393
+	tqApp->processEvents();
394 394
 
395 395
 	// If a cancel request is pending, ask gphoto to cancel
396 396
 	if (self->m_cancelPending)

+ 2
- 1
kamera/kcontrol/kamera.h View File

@@ -47,10 +47,11 @@ class KPopupMenu;
47 47
 class KKameraConfig : public KCModule
48 48
 {
49 49
 	Q_OBJECT
50
+  TQ_OBJECT
50 51
 	friend class KameraDeviceSelectDialog;
51 52
 
52 53
 public:
53
-	KKameraConfig(TQWidget *parent, const char *name, const TQStringList &);
54
+	KKameraConfig(TQWidget *tqparent, const char *name, const TQStringList &);
54 55
 	virtual ~KKameraConfig();
55 56
 
56 57
 	// KCModule interface methods

+ 18
- 18
kamera/kcontrol/kameraconfigdialog.cpp View File

@@ -42,9 +42,9 @@
42 42
 
43 43
 KameraConfigDialog::KameraConfigDialog(Camera */*camera*/,
44 44
 					CameraWidget *widget,
45
-					TQWidget *parent,
45
+					TQWidget *tqparent,
46 46
 					const char *name) :
47
-KDialogBase(parent, name, true, TQString::null, Ok|Cancel, Ok ),
47
+KDialogBase(tqparent, name, true, TQString(), Ok|Cancel, Ok ),
48 48
 m_widgetRoot(widget)
49 49
 {
50 50
     TQFrame *main = makeMainWidget();
@@ -56,9 +56,9 @@ m_widgetRoot(widget)
56 56
 	appendWidget(main, widget);
57 57
 }
58 58
 
59
-void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
59
+void KameraConfigDialog::appendWidget(TQWidget *tqparent, CameraWidget *widget)
60 60
 {
61
-	TQWidget *newParent = parent;
61
+	TQWidget *newParent = tqparent;
62 62
 	
63 63
 	CameraWidgetType widget_type;
64 64
 	const char *widget_name;
@@ -74,7 +74,7 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
74 74
 	
75 75
 	TQString whats_this = TQString::fromLocal8Bit(widget_info);	// gphoto2 doesn't seem to have any standard for i18n
76 76
 
77
-	// Add this widget to parent
77
+	// Add this widget to tqparent
78 78
 	switch(widget_type) {
79 79
 	case GP_WIDGET_WINDOW:
80 80
 		{
@@ -85,7 +85,7 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
85 85
 	case GP_WIDGET_SECTION:
86 86
 		{
87 87
 			if (!m_tabWidget)
88
-				m_tabWidget = new TQTabWidget(parent);
88
+				m_tabWidget = new TQTabWidget(tqparent);
89 89
 			TQWidget *tab = new TQWidget(m_tabWidget);
90 90
 			// widgets are to be aligned vertically in the tab
91 91
 			TQVBoxLayout *tabLayout = new TQVBoxLayout(tab, marginHint(),
@@ -104,7 +104,7 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
104 104
 		{
105 105
 			gp_widget_get_value(widget, &widget_value_string);
106 106
 
107
-			TQGrid *grid = new TQGrid(2, Horizontal, parent);
107
+			TQGrid *grid = new TQGrid(2,Qt::Horizontal, tqparent);
108 108
 			grid->setSpacing(spacingHint());
109 109
 			new TQLabel(TQString::fromLocal8Bit( widget_label )+":", grid);
110 110
 			TQLineEdit *lineEdit = new TQLineEdit(widget_value_string, grid);
@@ -123,13 +123,13 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
123 123
 			gp_widget_get_range(widget, &widget_low, &widget_high, &widget_increment);
124 124
 			gp_widget_get_value(widget, &widget_value_float);
125 125
 	
126
-			TQGroupBox *groupBox = new TQVGroupBox(widget_label, parent);
126
+			TQGroupBox *groupBox = new TQVGroupBox(widget_label, tqparent);
127 127
 			TQSlider *slider = new TQSlider(
128 128
 				( int )widget_low,
129 129
 				( int )widget_high,
130 130
 				( int )widget_increment,
131 131
 				( int )widget_value_float,
132
-				TQSlider::Horizontal,
132
+				Qt::Horizontal,
133 133
 				groupBox );
134 134
 			m_wmap.insert(widget, slider);
135 135
 		
@@ -142,7 +142,7 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
142 142
 		{
143 143
 			gp_widget_get_value(widget, &widget_value_int);
144 144
 		
145
-			TQCheckBox *checkBox = new TQCheckBox(widget_label, parent);
145
+			TQCheckBox *checkBox = new TQCheckBox(widget_label, tqparent);
146 146
 			checkBox->setChecked(widget_value_int);
147 147
 			m_wmap.insert(widget, checkBox);
148 148
 
@@ -160,9 +160,9 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
160 160
 			// for less than 5 options, align them horizontally
161 161
 			TQButtonGroup *buttonGroup;
162 162
 			if (count > 4)
163
-				buttonGroup = new TQVButtonGroup(widget_label, parent);
163
+				buttonGroup = new TQVButtonGroup(widget_label, tqparent);
164 164
 			else
165
-				buttonGroup = new TQHButtonGroup(widget_label, parent);
165
+				buttonGroup = new TQHButtonGroup(widget_label, tqparent);
166 166
 			
167 167
 			for(int i = 0; i < count; ++i) {
168 168
 				const char *widget_choice;
@@ -183,7 +183,7 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
183 183
 		{
184 184
 			gp_widget_get_value(widget, &widget_value_string);
185 185
 	
186
-			TQComboBox *comboBox = new TQComboBox(FALSE, parent);
186
+			TQComboBox *comboBox = new TQComboBox(FALSE, tqparent);
187 187
 			comboBox->clear();
188 188
 			for(int i = 0; i < gp_widget_count_choices(widget); ++i) {
189 189
 				const char *widget_choice;
@@ -206,14 +206,14 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
206 206
 			// I can't see a way of implementing this. Since there is
207 207
 			// no way of telling which button sent you a signal, we
208 208
 			// can't map to the appropriate widget->callback
209
-			new TQLabel(i18n("Button (not supported by KControl)"), parent);
209
+			new TQLabel(i18n("Button (not supported by KControl)"), tqparent);
210 210
 	
211 211
 			break;
212 212
 		}
213 213
 	case GP_WIDGET_DATE:
214 214
 		{
215 215
 			// TODO
216
-			new TQLabel(i18n("Date (not supported by KControl)"), parent);
216
+			new TQLabel(i18n("Date (not supported by KControl)"), tqparent);
217 217
 
218 218
 			break;
219 219
 		}
@@ -221,14 +221,14 @@ void KameraConfigDialog::appendWidget(TQWidget *parent, CameraWidget *widget)
221 221
 		return;
222 222
 	}
223 223
 
224
-	// Append all this widgets children
224
+	// Append all this widgets tqchildren
225 225
 	for(int i = 0; i < gp_widget_count_children(widget); ++i) {
226 226
 		CameraWidget *widget_child;
227 227
 		gp_widget_get_child(widget, i, &widget_child);
228 228
 		appendWidget(newParent, widget_child);
229 229
 	}
230 230
 	
231
-	// Things that must be done after all children were added
231
+	// Things that must be done after all tqchildren were added
232 232
 /*
233 233
 	switch (widget_type) {
234 234
 	case GP_WIDGET_SECTION:
@@ -309,7 +309,7 @@ void KameraConfigDialog::updateWidgetValue(CameraWidget *widget)
309 309
 
310 310
 void KameraConfigDialog::slotOk()
311 311
 {
312
-	// Copy Qt widget values into CameraWidget hierarchy
312
+	// Copy TQt widget values into CameraWidget hierarchy
313 313
 	updateWidgetValue(m_widgetRoot);
314 314
 
315 315
 	// 'ok' dialog

+ 3
- 2
kamera/kcontrol/kameraconfigdialog.h View File

@@ -34,15 +34,16 @@ extern "C" {
34 34
 class KameraConfigDialog : public KDialogBase
35 35
 {
36 36
 	Q_OBJECT
37
+  TQ_OBJECT
37 38
 public:
38 39
 	KameraConfigDialog(Camera *camera, CameraWidget *widget,
39
-			   TQWidget *parent = 0, const char *name = 0);
40
+			   TQWidget *tqparent = 0, const char *name = 0);
40 41
 
41 42
 private slots:
42 43
 	void slotOk();
43 44
 
44 45
 private:
45
-	void appendWidget(TQWidget *parent, CameraWidget *widget);
46
+	void appendWidget(TQWidget *tqparent, CameraWidget *widget);
46 47
 	void updateWidgetValue(CameraWidget *widget);
47 48
 	
48 49
 	TQMap<CameraWidget *, TQWidget *> m_wmap;

+ 14
- 14
kamera/kcontrol/kameradevice.cpp View File

@@ -86,7 +86,7 @@ bool KCamera::initInformation()
86 86
 	int index = gp_abilities_list_lookup_model(m_abilitylist, m_model.local8Bit().data());
87 87
 	if(index < 0) {
88 88
 		emit error(i18n("Description of abilities for camera %1 is not available."
89
-					" Configuration options may be incorrect.").arg(m_model));
89
+					" Configuration options may be incorrect.").tqarg(m_model));
90 90
 		return false;
91 91
 	}
92 92
         gp_abilities_list_get_abilities(m_abilitylist, index, &m_abilities);
@@ -197,7 +197,7 @@ void KCamera::load(KConfig *config)
197 197
 		m_model = config->readEntry("Model");
198 198
 	if (m_path.isNull())
199 199
 		m_path = config->readEntry("Path");
200
-	invalidateCamera();
200
+	tqinvalidateCamera();
201 201
 }
202 202
 
203 203
 void KCamera::save(KConfig *config)
@@ -209,7 +209,7 @@ void KCamera::save(KConfig *config)
209 209
 
210 210
 TQString KCamera::portName()
211 211
 {
212
-	TQString port = m_path.left(m_path.find(":")).lower();
212
+	TQString port = m_path.left(m_path.tqfind(":")).lower();
213 213
 	if (port == "serial") return i18n("Serial");
214 214
 	if (port == "usb") return i18n("USB");
215 215
 	return i18n("Unknown port");
@@ -223,17 +223,17 @@ void KCamera::setName(const TQString &name)
223 223
 void KCamera::setModel(const TQString &model)
224 224
 {
225 225
 	m_model = model;
226
-	invalidateCamera();
226
+	tqinvalidateCamera();
227 227
 	initInformation();
228 228
 }
229 229
 
230 230
 void KCamera::setPath(const TQString &path)
231 231
 {
232 232
 	m_path = path;
233
-	invalidateCamera();
233
+	tqinvalidateCamera();
234 234
 }
235 235
 
236
-void KCamera::invalidateCamera()
236
+void KCamera::tqinvalidateCamera()
237 237
 {
238 238
 	if (m_camera) {
239 239
 		gp_camera_free(m_camera);
@@ -270,8 +270,8 @@ CameraAbilities KCamera::abilities()
270 270
 
271 271
 // ---------- KameraSelectCamera ------------
272 272
 
273
-KameraDeviceSelectDialog::KameraDeviceSelectDialog(TQWidget *parent, KCamera *device)
274
-	: KDialogBase(parent, "kkameradeviceselect", true, i18n("Select Camera Device"), Ok | Cancel, Ok, true)
273
+KameraDeviceSelectDialog::KameraDeviceSelectDialog(TQWidget *tqparent, KCamera *device)
274
+	: KDialogBase(tqparent, "kkameradeviceselect", true, i18n("Select Camera Device"), Ok | Cancel, Ok, true)
275 275
 {
276 276
 	m_device = device;
277 277
 	connect(m_device, TQT_SIGNAL(error(const TQString &)),
@@ -282,7 +282,7 @@ KameraDeviceSelectDialog::KameraDeviceSelectDialog(TQWidget *parent, KCamera *de
282 282
 	TQWidget *page = new TQWidget( this );
283 283
 	setMainWidget(page);
284 284
 
285
-	// a layout with vertical boxes
285
+	// a tqlayout with vertical boxes
286 286
 	TQHBoxLayout *topLayout = new TQHBoxLayout(page, 0, KDialog::spacingHint());
287 287
 
288 288
 	// the models list
@@ -293,7 +293,7 @@ KameraDeviceSelectDialog::KameraDeviceSelectDialog(TQWidget *parent, KCamera *de
293 293
 	connect(m_modelSel, TQT_SIGNAL(selectionChanged(TQListViewItem *)),
294 294
         TQT_SLOT(slot_setModel(TQListViewItem *)));
295 295
 	// make sure listview only as wide as it needs to be
296
-	m_modelSel->setSizePolicy(TQSizePolicy(TQSizePolicy::Maximum,
296
+	m_modelSel->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Maximum,
297 297
 		TQSizePolicy::Preferred));
298 298
 
299 299
 	TQVBoxLayout *rightLayout = new TQVBoxLayout(0L, 0, KDialog::spacingHint());
@@ -347,7 +347,7 @@ KameraDeviceSelectDialog::KameraDeviceSelectDialog(TQWidget *parent, KCamera *de
347 347
 	for (int i = 0; i < gphoto_ports; i++) {
348 348
 		if (gp_port_info_list_get_info(list, i, &info) >= 0) {
349 349
 			if (strncmp(info.path, "serial:", 7) == 0)
350
-				m_serialPortCombo->insertItem(TQString::fromLatin1(info.path).mid(7));
350
+				m_serialPortCombo->insertItem(TQString::tqfromLatin1(info.path).mid(7));
351 351
 		}
352 352
 	}
353 353
 	gp_port_info_list_free(list);
@@ -403,7 +403,7 @@ void KameraDeviceSelectDialog::save()
403 403
 void KameraDeviceSelectDialog::load()
404 404
 {
405 405
 	TQString path = m_device->path();
406
-	TQString port = path.left(path.find(":")).lower();
406
+	TQString port = path.left(path.tqfind(":")).lower();
407 407
 
408 408
 	if (port == "serial") setPortType(INDEX_SERIAL);
409 409
 	if (port == "usb") setPortType(INDEX_USB);
@@ -432,7 +432,7 @@ void KameraDeviceSelectDialog::slot_setModel(TQListViewItem *item)
432 432
 	int index = gp_abilities_list_lookup_model(m_device->m_abilitylist, model.local8Bit().data());
433 433
 	if(index < 0) {
434 434
 		slot_error(i18n("Description of abilities for camera %1 is not available."
435
-				" Configuration options may be incorrect.").arg(model));
435
+				" Configuration options may be incorrect.").tqarg(model));
436 436
 	}
437 437
 	int result = gp_abilities_list_get_abilities(m_device->m_abilitylist, index, &abilities);
438 438
 	if (result == GP_OK) {
@@ -452,7 +452,7 @@ void KameraDeviceSelectDialog::slot_setModel(TQListViewItem *item)
452 452
 			setPortType(INDEX_USB);
453 453
 	} else {
454 454
 		slot_error(i18n("Description of abilities for camera %1 is not available."
455
-			     " Configuration options may be incorrect.").arg(model));
455
+			     " Configuration options may be incorrect.").tqarg(model));
456 456
 	}
457 457
 }
458 458
 

+ 4
- 2
kamera/kcontrol/kameradevice.h View File

@@ -40,10 +40,11 @@ class TQRadioButton;
40 40
 class KCamera : public TQObject {
41 41
 	friend class KameraDeviceSelectDialog;
42 42
 	Q_OBJECT
43
+  TQ_OBJECT
43 44
 public:
44 45
 	KCamera(const TQString &name, const TQString &path);
45 46
 	~KCamera();
46
-	void invalidateCamera();
47
+	void tqinvalidateCamera();
47 48
 	bool configure();
48 49
 	void load(KConfig *m_config);
49 50
 	void save(KConfig *m_config);
@@ -88,8 +89,9 @@ protected:
88 89
 class KameraDeviceSelectDialog : public KDialogBase
89 90
 {
90 91
 	Q_OBJECT
92
+  TQ_OBJECT
91 93
 public:
92
-	KameraDeviceSelectDialog(TQWidget *parent, KCamera *device);
94
+	KameraDeviceSelectDialog(TQWidget *tqparent, KCamera *device);
93 95
 	void save();
94 96
 	void load();
95 97
 protected slots:

+ 8
- 8
kamera/kioslave/kamera.cpp View File

@@ -55,7 +55,7 @@ extern "C"
55 55
 {
56 56
 	KDE_EXPORT int kdemain(int argc, char **argv);
57 57
 
58
-	static void frontendCameraStatus(GPContext *context, const char *format, va_list args, void *data);
58
+	static void frontendCameratqStatus(GPContext *context, const char *format, va_list args, void *data);
59 59
 	static unsigned int frontendProgressStart(
60 60
 		GPContext *context, float totalsize, const char *format,
61 61
 		va_list args, void *data
@@ -242,7 +242,7 @@ void KameraProtocol::get(const KURL &url)
242 242
 
243 243
 #undef GPHOTO_TEXT_FILE
244 244
 	// emit info message
245
-	infoMessage( i18n("Retrieving data from camera <b>%1</b>").arg(url.user()) );
245
+	infoMessage( i18n("Retrieving data from camera <b>%1</b>").tqarg(url.user()) );
246 246
 
247 247
 	// Note: There's no need to re-read directory for each get() anymore
248 248
 	gp_file_new(&m_file);
@@ -574,7 +574,7 @@ void KameraProtocol::listDir(const KURL &url)
574 574
 		gp_list_free (list);
575 575
 
576 576
 		/* Avoid duplicated entry for usb: and usb:001,042 entries. */
577
-		if (ports.contains("usb:") && names[ports["usb:"]]!="usb:")
577
+		if (ports.tqcontains("usb:") && names[ports["usb:"]]!="usb:")
578 578
 			ports.remove("usb:");
579 579
 
580 580
 		for (it = groupList.begin(); it != groupList.end(); it++) {
@@ -606,7 +606,7 @@ void KameraProtocol::listDir(const KURL &url)
606 606
 			xurl.setProtocol("camera");
607 607
 			xurl.setUser(*it);
608 608
 			/* Avoid setting usb:xxx,yyy. */
609
-			if (m_cfgPath.contains("usb:")>0) {
609
+			if (m_cfgPath.tqcontains("usb:")>0) {
610 610
 				names[*it] = "usb:";
611 611
 				xurl.setHost("usb:");
612 612
 			} else {
@@ -795,7 +795,7 @@ void KameraProtocol::setHost(const TQString& host, int port, const TQString& use
795 795
 		}
796 796
 
797 797
 		// register gphoto2 callback functions
798
-		gp_context_set_status_func(m_context, frontendCameraStatus, this);
798
+		gp_context_set_status_func(m_context, frontendCameratqStatus, this);
799 799
 		gp_context_set_progress_funcs(m_context, frontendProgressStart, frontendProgressUpdate, NULL, this);
800 800
 		// gp_camera_set_message_func(m_camera, ..., this)
801 801
 
@@ -881,7 +881,7 @@ void KameraProtocol::translateFileToUDS(UDSEntry &udsEntry, const CameraFileInfo
881 881
 
882 882
 	if (info.file.fields & GP_FILE_INFO_TYPE) {
883 883
 		atom.m_uds = UDS_MIME_TYPE;
884
-		atom.m_str = TQString::fromLatin1(info.file.type);
884
+		atom.m_str = TQString::tqfromLatin1(info.file.type);
885 885
 		udsEntry.append(atom);
886 886
 	}
887 887
 
@@ -890,7 +890,7 @@ void KameraProtocol::translateFileToUDS(UDSEntry &udsEntry, const CameraFileInfo
890 890
 		atom.m_long = 0;
891 891
 		atom.m_long |= (info.file.permissions & GP_FILE_PERM_READ) ? (S_IRUSR | S_IRGRP | S_IROTH) : 0;
892 892
 		// we cannot represent individual FP_FILE_PERM_DELETE permission in the Unix access scheme
893
-		// since the parent directory's write permission defines that
893
+		// since the tqparent directory's write permission defines that
894 894
 		udsEntry.append(atom);
895 895
 	} else {
896 896
 		// basic permissions, in case the camera doesn't provide permissions info
@@ -1028,7 +1028,7 @@ unsigned int frontendProgressStart(
1028 1028
 }
1029 1029
 
1030 1030
 // this callback function is activated on every status message from gphoto2
1031
-static void frontendCameraStatus(GPContext * /*context*/, const char *format, va_list args, void *data)
1031
+static void frontendCameratqStatus(GPContext * /*context*/, const char *format, va_list args, void *data)
1032 1032
 {
1033 1033
 	KameraProtocol *object = (KameraProtocol*)data;
1034 1034
 	char *status;

+ 8
- 8
kcoloredit/colorselector.cpp View File

@@ -30,7 +30,7 @@
30 30
 #include "texteditselection.h"
31 31
 #include "colorselector.h"
32 32
 
33
-ColorSelector::ColorSelector(TQWidget *parent, const char *name ) : TQWidget(parent, name) {
33
+ColorSelector::ColorSelector(TQWidget *tqparent, const char *name ) : TQWidget(tqparent, name) {
34 34
 	fComponentsMode = false;
35 35
 	TQVBoxLayout* topLayout = new TQVBoxLayout(this, 4);
36 36
 	/*
@@ -53,7 +53,7 @@ ColorSelector::ColorSelector(TQWidget *parent, const char *name ) : TQWidget(par
53 53
 	topLayout->addWidget(gradientSelection, 10);
54 54
 	KSeparator* hLine = new KSeparator(KSeparator::HLine, this);
55 55
 	topLayout->addWidget(hLine);
56
-	TQHBoxLayout* layout = new TQHBoxLayout();
56
+	TQHBoxLayout* tqlayout = new TQHBoxLayout();
57 57
 	TextEditSelection* textEditSelection = new TextEditSelection(this);
58 58
 	connect(textEditSelection, TQT_SIGNAL( valueChanged(Color*) ), TQT_SLOT( slotSetColor(Color*) ));
59 59
 	connect(this, TQT_SIGNAL( valueChanged(Color*) ), textEditSelection, TQT_SLOT( slotSetValue(Color*) ));
@@ -73,7 +73,7 @@ ColorSelector::ColorSelector(TQWidget *parent, const char *name ) : TQWidget(par
73 73
 	TQVBoxLayout* colorChangeSliderLayout = new TQVBoxLayout(colorChangeSliderWidget, 1);
74 74
 	colorChangeSliderLayout->setMargin(0);
75 75
 	TQSlider* colorChangeSlider = new TQSlider(0, MAX_COLOR_CHANGE_VALUE,
76
-		MAX_COLOR_CHANGE_VALUE/4, colorChangeValue, TQSlider::Horizontal, colorChangeSliderWidget);
76
+		MAX_COLOR_CHANGE_VALUE/4, colorChangeValue, Qt::Horizontal, colorChangeSliderWidget);
77 77
 	colorChangeSlider->setTickInterval(colorChangeSlider->pageStep());
78 78
 	colorChangeSlider->setTickmarks(TQSlider::Above);
79 79
 	connect(colorChangeSlider, TQT_SIGNAL( valueChanged(int) ), TQT_SLOT( slotColorChangeValueChanged(int) ));
@@ -88,17 +88,17 @@ ColorSelector::ColorSelector(TQWidget *parent, const char *name ) : TQWidget(par
88 88
 	colorChangeLayout->addStretch(10);
89 89
 	colorChangeLayout->addWidget(colorChangeSliderWidget);
90 90
 	colorChangeLayout->addStretch(10);
91
-	layout->addLayout(colorChangeLayout, 10);
91
+	tqlayout->addLayout(colorChangeLayout, 10);
92 92
 	m_color.setComponents(RGB_MAX_COMPONENT_VALUE, RGB_MAX_COMPONENT_VALUE, RGB_MAX_COMPONENT_VALUE);
93 93
 	slotColorReplace();
94 94
 	KSeparator* vLine = new KSeparator(KSeparator::VLine, this);
95
-	layout->addWidget(vLine);
96
-	layout->addWidget(textEditSelection, 1);
95
+	tqlayout->addWidget(vLine);
96
+	tqlayout->addWidget(textEditSelection, 1);
97 97
 	colorPatch = new KColorPatch(this);
98 98
 	connect(colorPatch, TQT_SIGNAL( colorChanged(const TQColor&) ), TQT_SLOT( slotSetColor(const TQColor&) ));
99 99
 	colorPatch->setMinimumSize(80, 64);
100
-	layout->addWidget(colorPatch, 10);
101
-	topLayout->addLayout(layout);
100
+	tqlayout->addWidget(colorPatch, 10);
101
+	topLayout->addLayout(tqlayout);
102 102
 }
103 103
 ColorSelector::~ColorSelector() {
104 104
 }

+ 2
- 1
kcoloredit/colorselector.h View File

@@ -31,10 +31,11 @@
31 31
  */
32 32
 class ColorSelector : public TQWidget  {
33 33
 	Q_OBJECT
34
+  TQ_OBJECT
34 35
 
35 36
 public:
36 37
 	/** constructs a color selector widget */
37
-	ColorSelector(TQWidget *parent=0, const char *name=0);
38
+	ColorSelector(TQWidget *tqparent=0, const char *name=0);
38 39
 	~ColorSelector();
39 40
 	/** @return the selected color */
40 41
 	const Color& color();

+ 2
- 2
kcoloredit/editablestreamhistory.h View File

@@ -37,7 +37,7 @@ public:
37 37
 	/** Pastes a stream at index. Uses undo/redo history */
38 38
 	void paste(const int index, EDITABLE_STREAM& pasteStream);
39 39
 	/** Replaces a stream at index. Uses undo/redo history */
40
-	void replace(const int index, EDITABLE_STREAM& replaceStream);
40
+	void tqreplace(const int index, EDITABLE_STREAM& replaceStream);
41 41
 	/** @return Whether undo possible */
42 42
 	bool undoPossible();
43 43
 	/** @return Whether redo possible */
@@ -76,7 +76,7 @@ template <class EDITABLE_STREAM> void
76 76
 }
77 77
 
78 78
 template <class EDITABLE_STREAM> void
79
-	EditableStreamHistory<EDITABLE_STREAM>::replace(const int index, EDITABLE_STREAM& replaceStream) {
79
+	EditableStreamHistory<EDITABLE_STREAM>::tqreplace(const int index, EDITABLE_STREAM& replaceStream) {
80 80
 	m_editableStream->cut(index, replaceStream.length());
81 81
 	m_editableStream->paste(index, replaceStream);
82 82
 }

+ 8
- 8
kcoloredit/gradientselection.cpp View File

@@ -24,15 +24,15 @@
24 24
 #include "main.h"
25 25
 #include "gradientselection.h"
26 26
 
27
-GradientSelection::GradientSelection(TQWidget *parent, const char *name ) : TQWidget(parent,name) {
27
+GradientSelection::GradientSelection(TQWidget *tqparent, const char *name ) : TQWidget(tqparent,name) {
28 28
 	TQGridLayout* topLayout = new TQGridLayout(this, 2, 2, 0);
29
-	TQHBoxLayout* layout = new TQHBoxLayout(0);
30
-	layout->setMargin(3);
29
+	TQHBoxLayout* tqlayout = new TQHBoxLayout(0);
30
+	tqlayout->setMargin(3);
31 31
 	xyColorSelector = new KXYColorSelector(this);
32 32
 	connect(xyColorSelector, TQT_SIGNAL( valueChanged(int, int) ),
33 33
 		TQT_SLOT( slotXyColorSelectorPosChanged(int, int) ));
34
-	layout->addWidget(xyColorSelector);
35
-	topLayout->addLayout(layout, 0, 0);
34
+	tqlayout->addWidget(xyColorSelector);
35
+	topLayout->addLayout(tqlayout, 0, 0);
36 36
 	topLayout->setRowStretch(0, 10);
37 37
 	topLayout->setRowStretch(1, 0);
38 38
 	TQVBoxLayout* xyColorSelectorLayout = new TQVBoxLayout();
@@ -54,7 +54,7 @@ GradientSelection::GradientSelection(TQWidget *parent, const char *name ) : TQWi
54 54
 	xyColorSelectorLayout->addLayout(buttonsLayout);
55 55
 	xyColorSelectorLayout->addSpacing(2);
56 56
 	topLayout->addLayout(xyColorSelectorLayout, 1, 0);
57
-	zColorSelector = new KZColorSelector(KZColorSelector::Vertical, this);
57
+	zColorSelector = new KZColorSelector(Qt::Vertical, this);
58 58
 	connect(zColorSelector, TQT_SIGNAL( valueChanged(int) ),
59 59
 		TQT_SLOT( slotZColorSelectorPosChanged(int) ));
60 60
 	zColorSelector->setFixedWidth(36);
@@ -218,7 +218,7 @@ void GradientSelection::slotXyColorSelectorPosChanged(int x, int y) {
218 218
 }
219 219
 
220 220
 void GradientSelection::slotZColorSelectorPosChanged(int y) {
221
-	bool repaintZColorSelector = false;
221
+	bool tqrepaintZColorSelector = false;
222 222
 	switch(zColorSelectorComponentIndex) {
223 223
 		case H_COMPONENT:
224 224
 			hComponent = y;
@@ -237,7 +237,7 @@ void GradientSelection::slotZColorSelectorPosChanged(int y) {
237 237
 	rgbColor.setHsv(hComponent, sComponent, vComponent);
238 238
 	color.setComponents(rgbColor.red(), rgbColor.green(), rgbColor.blue());
239 239
 	updateXyColorSelector(false);
240
-	if(repaintZColorSelector)
240
+	if(tqrepaintZColorSelector)
241 241
 		updateZColorSelector();
242 242
 	emit valueChanged(&color);
243 243
 }

+ 2
- 1
kcoloredit/gradientselection.h View File

@@ -32,10 +32,11 @@
32 32
   */
33 33
 class GradientSelection : public TQWidget  {
34 34
    Q_OBJECT
35
+  TQ_OBJECT
35 36
 
36 37
 public:
37 38
 	/** Constructs the widget */
38
-	GradientSelection(TQWidget *parent=0, const char *name=0);
39
+	GradientSelection(TQWidget *tqparent=0, const char *name=0);
39 40
 	~GradientSelection();
40 41
 	/** Enables or disables the color synchronize button */
41 42
 	void enableSynchronizeColorButton(bool enable);

+ 1
- 1
kcoloredit/imageselection.cpp View File

@@ -17,7 +17,7 @@
17 17
 
18 18
 #include "imageselection.h"
19 19
 
20
-ImageSelection::ImageSelection(TQWidget *parent, const char *name ) : TQWidget(parent,name) {
20
+ImageSelection::ImageSelection(TQWidget *tqparent, const char *name ) : TQWidget(tqparent,name) {
21 21
 }
22 22
 ImageSelection::~ImageSelection(){
23 23
 }

+ 2
- 1
kcoloredit/imageselection.h View File

@@ -27,10 +27,11 @@
27 27
   */
28 28
 class ImageSelection : public TQWidget  {
29 29
    Q_OBJECT
30
+  TQ_OBJECT
30 31
 
31 32
 public:
32 33
 	/** constructs the widget */
33
-	ImageSelection(TQWidget *parent=0, const char *name=0);
34
+	ImageSelection(TQWidget *tqparent=0, const char *name=0);
34 35
 	~ImageSelection();
35 36
 	
36 37
 signals:

+ 2
- 2
kcoloredit/kcolorchooser.cpp View File

@@ -55,7 +55,7 @@ int main(int argc, char *argv[])
55 55
   
56 56
   KColorDialog dlg;
57 57
 
58
-  dlg.setColor(Qt::blue); // Just a color
58
+  dlg.setColor(TQt::blue); // Just a color
59 59
 
60 60
   app.connect(&dlg, TQT_SIGNAL(finished()), TQT_SLOT(quit()));
61 61
 
@@ -65,6 +65,6 @@ int main(int argc, char *argv[])
65 65
   KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
66 66
   const  TQColor c = dlg.color();
67 67
   if ( args->isSet("print") && c.isValid() ) {
68
-      std::cout << c.name().utf8().data() << std::endl;
68
+      std::cout << TQString(c.name()).utf8().data() << std::endl;
69 69
   }
70 70
 }  

+ 15
- 15
kcoloredit/kcoloredit.cpp View File

@@ -64,39 +64,39 @@ KColorEditApp::~KColorEditApp() {
64 64
 void KColorEditApp::initActions()
65 65
 {
66 66
   // File actiojns
67
-  KStdAction::openNew( this, TQT_SLOT( slotFileNew() ), actionCollection() );
68
-  KStdAction::open( this, TQT_SLOT( slotFileOpen() ), actionCollection() );
69
-  KStdAction::saveAs( this, TQT_SLOT( slotFileSaveAs() ), actionCollection() );
70
-  KStdAction::close( this, TQT_SLOT( slotClose() ), actionCollection() );
71
-  KStdAction::quit( this, TQT_SLOT( slotQuit() ), actionCollection() );
72
-  m_actSave = KStdAction::save( this, TQT_SLOT( slotFileSave() ),
67
+  KStdAction::openNew( TQT_TQOBJECT(this), TQT_SLOT( slotFileNew() ), actionCollection() );
68
+  KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT( slotFileOpen() ), actionCollection() );
69
+  KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT( slotFileSaveAs() ), actionCollection() );
70
+  KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT( slotClose() ), actionCollection() );
71
+  KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( slotQuit() ), actionCollection() );
72
+  m_actSave = KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT( slotFileSave() ),
73 73
           actionCollection() );
74
-  m_actRecent = KStdAction::openRecent( this,
74
+  m_actRecent = KStdAction::openRecent( TQT_TQOBJECT(this),
75 75
           TQT_SLOT( slotFileOpenRecent( const KURL& ) ), actionCollection() );
76 76
 
77 77
   ( void ) new KAction( i18n("New &Window"), kapp->miniIcon(), KShortcut(),
78
-          this, TQT_SLOT( slotFileNewWindow() ), actionCollection(),
78
+          TQT_TQOBJECT(this), TQT_SLOT( slotFileNewWindow() ), actionCollection(),
79 79
           "file_new_window" );
80 80
 
81 81
   // Edit actions
82
-  m_actCut = KStdAction::cut( this, TQT_SLOT( slotEditCut() ),
82
+  m_actCut = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT( slotEditCut() ),
83 83
           actionCollection() );
84
-  m_actCopy = KStdAction::copy( this, TQT_SLOT( slotEditCopy() ),
84
+  m_actCopy = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT( slotEditCopy() ),
85 85
           actionCollection() );
86
-  m_actPaste = KStdAction::paste( this, TQT_SLOT( slotEditPaste() ),
86
+  m_actPaste = KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT( slotEditPaste() ),
87 87
           actionCollection() );
88 88
 
89 89
   m_actPaste->setEnabled( false );
90 90
 
91 91
   // Color Menu
92
-  m_actNames = new KToggleAction( i18n("Show &Color Names"), KShortcut(), this,
92
+  m_actNames = new KToggleAction( i18n("Show &Color Names"), KShortcut(), TQT_TQOBJECT(this),
93 93
           TQT_SLOT( slotViewColorNames() ), actionCollection(),
94 94
           "color_view_names" );
95 95
   m_actNames->setCheckedState(i18n("Hide &Color Names"));
96
-  m_actPalette = new KAction( i18n("From &Palette"), KShortcut(), this,
96
+  m_actPalette = new KAction( i18n("From &Palette"), KShortcut(), TQT_TQOBJECT(this),
97 97
           TQT_SLOT( slotColorFromPalette() ), actionCollection(),
98 98
           "color_from_palette" );
99
-  ( void ) new KAction( i18n("From &Screen"), KShortcut(), this,
99
+  ( void ) new KAction( i18n("From &Screen"), KShortcut(), TQT_TQOBJECT(this),
100 100
           TQT_SLOT( slotColorFromScreen() ), actionCollection(),
101 101
           "color_from_screen" );
102 102
 }
@@ -104,7 +104,7 @@ void KColorEditApp::initActions()
104 104
 void KColorEditApp::initStatusBar()
105 105
 {
106 106
   statusBar()->insertItem(i18n("Ready."), ID_STATUS_MSG, 1);
107
-  statusBar()->setItemAlignment( ID_STATUS_MSG, Qt::AlignLeft );
107
+  statusBar()->setItemAlignment( ID_STATUS_MSG, TQt::AlignLeft );
108 108
 }
109 109
 
110 110
 void KColorEditApp::initDocument()

+ 3
- 2
kcoloredit/kcoloredit.h View File

@@ -21,7 +21,7 @@
21 21
 
22 22
 #include <config.h>
23 23
 
24
-// include files for Qt
24
+// include files for TQt
25 25
 #include <tqevent.h>
26 26
 #include <tqstringlist.h>
27 27
 
@@ -54,6 +54,7 @@ class KColorEditView;
54 54
 class KColorEditApp : public KMainWindow
55 55
 {
56 56
   Q_OBJECT
57
+  TQ_OBJECT
57 58
 
58 59
   friend class KColorEditView;
59 60
 
@@ -73,7 +74,7 @@ class KColorEditApp : public KMainWindow
73 74
     KColorEditDoc *document() const;
74 75
 
75 76
   protected:
76
-    /** save general Options like all bar positions and status as well as the geometry and the recent file list to the configuration
77
+    /** save general Options like all bar positions and status as well as the tqgeometry and the recent file list to the configuration
77 78
      * file
78 79
      */
79 80
     void saveOptions();

+ 9
- 9
kcoloredit/kcoloreditdoc.cpp View File

@@ -15,7 +15,7 @@
15 15
  *                                                                         *
16 16
  ***************************************************************************/
17 17
 
18
-// include files for Qt
18
+// include files for TQt
19 19
 #include <tqdir.h>
20 20
 #include <tqfileinfo.h>
21 21
 #include <tqwidget.h>
@@ -31,7 +31,7 @@
31 31
 #include "kcoloreditview.h"
32 32
 #include "resource.h"
33 33
 
34
-KColorEditDoc::KColorEditDoc(TQWidget *parent, const char *name) : TQObject(parent, name),
34
+KColorEditDoc::KColorEditDoc(TQWidget *tqparent, const char *name) : TQObject(tqparent, name),
35 35
 	m_palette(), m_paletteHistory(&m_palette, 0) {
36 36
 	m_pViewList = new TQPtrList<KColorEditView>();
37 37
 	m_pViewList->setAutoDelete(true);
@@ -106,10 +106,10 @@ bool KColorEditDoc::saveModified()
106 106
 
107 107
   if(m_modified)
108 108
   {
109
-    KColorEditApp *window=(KColorEditApp *) parent();
109
+    KColorEditApp *window=(KColorEditApp *) tqparent();
110 110
     int want_save = KMessageBox::warningYesNoCancel(window,
111 111
                                          i18n("The current file has been modified.\n"
112
-                                              "Do you want to save it?"), TQString::null, KStdGuiItem::save(), i18n("Do Not Save"));
112
+                                              "Do you want to save it?"), TQString(), KStdGuiItem::save(), i18n("Do Not Save"));
113 113
     switch(want_save)
114 114
     {
115 115
       case KMessageBox::Yes:
@@ -175,7 +175,7 @@ bool KColorEditDoc::openDocument(const TQString& filename) {
175 175
 		setPaletteCursorPos(m_palette.length());
176 176
 		setPaletteSelection(0, 0);
177 177
 		slotRedrawAllViews(0, true);
178
-        KColorEditApp *window=(KColorEditApp*)parent();
178
+        KColorEditApp *window=(KColorEditApp*)tqparent();
179 179
         window->setCaption(m_title);
180 180
 	}
181 181
 	return true;
@@ -235,7 +235,7 @@ void KColorEditDoc::copyToClipboard(Palette& palette) {
235 235
 	TQString text;
236 236
 	TQTextOStream stream(&text);
237 237
 	palette.save(stream, 0, false);
238
-	KApplication::clipboard()->setText(text);
238
+	KApplication::tqclipboard()->setText(text);
239 239
 
240 240
     emit clipboardChanged();
241 241
 }
@@ -260,7 +260,7 @@ void KColorEditDoc::paste() {
260 260
 	Palette palettePaste;
261 261
 	TQString text;
262 262
 	TQTextIStream stream(&text);
263
-	text = KApplication::clipboard()->text();
263
+	text = KApplication::tqclipboard()->text();
264 264
 	if(palettePaste.load( stream, false )) {
265 265
 		m_paletteHistory.paste(paletteCursorPos(), palettePaste);
266 266
 		setPaletteSelection(paletteCursorPos(), paletteCursorPos() +
@@ -281,11 +281,11 @@ void KColorEditDoc::insert(int index, const Color& color) {
281 281
 	slotRedrawAllViews(0);
282 282
 }
283 283
 
284
-void KColorEditDoc::replace(int index, const Color& color) {
284
+void KColorEditDoc::tqreplace(int index, const Color& color) {
285 285
 	Palette paletteReplace;
286 286
 	Color* replaceColor = new Color(color);
287 287
 	paletteReplace.append(replaceColor);
288
-	m_paletteHistory.replace(index, paletteReplace);
288
+	m_paletteHistory.tqreplace(index, paletteReplace);
289 289
 	setPaletteSelection(0, 0);
290 290
 	setModified(true);
291 291
 	slotRedrawAllViews(0);

+ 4
- 3
kcoloredit/kcoloreditdoc.h View File

@@ -44,13 +44,14 @@ class KColorEditView;
44 44
   * @author Source Framework Automatically Generated by KDevelop, (c) The KDevelop Team.
45 45
   * @version KDevelop version 0.4 code generation
46 46
   */
47
-class KColorEditDoc : public QObject
47
+class KColorEditDoc : public TQObject
48 48
 {
49 49
   Q_OBJECT
50
+  TQ_OBJECT
50 51
 
51 52
   public:
52 53
     /** Constructor for the fileclass of the application */
53
-    KColorEditDoc(TQWidget *parent, const char *name=0);
54
+    KColorEditDoc(TQWidget *tqparent, const char *name=0);
54 55
     /** Destructor for the fileclass of the application */
55 56
     ~KColorEditDoc();
56 57
 
@@ -111,7 +112,7 @@ class KColorEditDoc : public QObject
111 112
 		/** Inserts a color at index */
112 113
 		void insert(int index, const Color& color);
113 114
 		/** Replaces a color at index */
114
-		void replace(int index, const Color& color);
115
+		void tqreplace(int index, const Color& color);
115 116
 
116 117
 	protected:
117 118
 		/** Sets an error string if an IO operation was unsuccesfull */

+ 10
- 10
kcoloredit/kcoloreditview.cpp View File

@@ -15,7 +15,7 @@
15 15
  *                                                                         *
16 16
  ***************************************************************************/
17 17
 
18
-// include files for Qt
18
+// include files for TQt
19 19
 #include <tqpainter.h>
20 20
 #include <tqlayout.h>
21 21
 #include <tqpushbutton.h>
@@ -35,7 +35,7 @@
35 35
 #include "kcoloredit.h"
36 36
 #include "palette.h"
37 37
 
38
-KColorEditView::KColorEditView(TQWidget *parent, const char *name) : TQSplitter(parent, name) {
38
+KColorEditView::KColorEditView(TQWidget *tqparent, const char *name) : TQSplitter(tqparent, name) {
39 39
 	colorSelector = new ColorSelector(this);
40 40
 	colorSelector->slotSetColor(
41 41
 		Color( RGB_MAX_COMPONENT_VALUE, RGB_MAX_COMPONENT_VALUE, RGB_MAX_COMPONENT_VALUE, "" ));
@@ -43,7 +43,7 @@ KColorEditView::KColorEditView(TQWidget *parent, const char *name) : TQSplitter(
43 43
 	TQVBoxLayout* paletteLayout = new TQVBoxLayout(paletteViewArea);
44 44
 	paletteView = new PaletteView(16, 16, 2, this, paletteViewArea);
45 45
 	paletteLayout->addWidget(paletteView, 10);
46
-	TQHBoxLayout* layout = new TQHBoxLayout();
46
+	TQHBoxLayout* tqlayout = new TQHBoxLayout();
47 47
 	TQVBoxLayout* addColorLayout = new TQVBoxLayout(4);
48 48
 	addColorLayout->setMargin(8);
49 49
 	TQHBoxLayout* buttonsLayout = new TQHBoxLayout(4);
@@ -70,7 +70,7 @@ KColorEditView::KColorEditView(TQWidget *parent, const char *name) : TQSplitter(
70 70
 	//	paletteView, TQT_SLOT( slotCursorFollowsChosenColor(bool) ));
71 71
 	//cursorFollowsChosenColor->toggle();
72 72
 	paletteView->slotCursorFollowsChosenColor(true);
73
-	layout->addLayout(addColorLayout, 0);
73
+	tqlayout->addLayout(addColorLayout, 0);
74 74
 	TQVGroupBox* colorAtCursorFrame = new TQVGroupBox(i18n("Color at Cursor"), paletteViewArea);
75 75
 	TQWidget* colorAtCursorFrameArea = new TQWidget(colorAtCursorFrame);
76 76
 	TQVBoxLayout* colorAtCursorLayout = new TQVBoxLayout(colorAtCursorFrameArea, 4);
@@ -127,10 +127,10 @@ KColorEditView::KColorEditView(TQWidget *parent, const char *name) : TQSplitter(
127 127
 	colorAtCursorRgbStringLayout->addWidget(colorAtCursorRgbStringValueLabel);
128 128
 	colorAtCursorRgbStringLayout->addStretch();
129 129
 	colorAtCursorLayout->addLayout(colorAtCursorRgbStringLayout);
130
-	layout->addWidget(colorAtCursorFrame, 10);
131
-	layout->addSpacing(8);
130
+	tqlayout->addWidget(colorAtCursorFrame, 10);
131
+	tqlayout->addSpacing(8);
132 132
 	paletteLayout->addSpacing(4);
133
-	paletteLayout->addLayout(layout);
133
+	paletteLayout->addLayout(tqlayout);
134 134
 	paletteLayout->addSpacing(4);
135 135
 	inColorNameChanging = false;
136 136
 	doNotUpdateColorLabels = false;
@@ -145,7 +145,7 @@ void KColorEditView::setColorAtCursorComponentValueLabelSizes(TQLabel* const lab
145 145
 }
146 146
 
147 147
 KColorEditDoc *KColorEditView::document() const {
148
-  KColorEditApp *theApp=(KColorEditApp *) parentWidget();
148
+  KColorEditApp *theApp=(KColorEditApp *) tqparentWidget();
149 149
 
150 150
   return theApp->document();
151 151
 }
@@ -234,7 +234,7 @@ void KColorEditView::slotAddColor() {
234 234
 
235 235
         case REPLACE_COLOR:
236 236
             if(index < palette->length())
237
-                document()->replace(index, color);
237
+                document()->tqreplace(index, color);
238 238
             else
239 239
                 document()->insert(index, color);
240 240
             break;
@@ -274,7 +274,7 @@ void KColorEditView::slotSetColorName(const TQString& name) {
274 274
 				palette->color(cursorPos)->component(Color::BLUE_INDEX),
275 275
 				name);
276 276
 			doNotUpdateColorLabels = true;
277
-			document()->replace(cursorPos, newColor);
277
+			document()->tqreplace(cursorPos, newColor);
278 278
 			doNotUpdateColorLabels = false;
279 279
 		}
280 280
 	}

+ 4
- 3
kcoloredit/kcoloreditview.h View File

@@ -22,7 +22,7 @@
22 22
 #include <config.h>
23 23
 #endif 
24 24
 
25
-// include files for Qt
25
+// include files for TQt
26 26
 #include <tqsplitter.h>
27 27
 #include <tqcheckbox.h>
28 28
 #include <tqlabel.h>
@@ -43,14 +43,15 @@ class KColorEditDoc;
43 43
  */
44 44
 class KColorEditView : public TQSplitter {
45 45
   Q_OBJECT
46
+  TQ_OBJECT
46 47
 
47 48
   public:
48 49
     /** Constructor for the main view */
49
-    KColorEditView(TQWidget *parent = 0, const char *name = 0);
50
+    KColorEditView(TQWidget *tqparent = 0, const char *name = 0);
50 51
     /** Destructor for the main view */
51 52
     ~KColorEditView();
52 53
 
53
-    /** returns a pointer to the document connected to the view instance. Mind that this method requires a KColorEditApp instance as a parent
54
+    /** returns a pointer to the document connected to the view instance. Mind that this method requires a KColorEditApp instance as a tqparent
54 55
      * widget to get to the window document pointer by calling the KColorEditApp::getDocument() method.
55 56
      *
56 57
      * @see KColorEditApp#getDocument

+ 22
- 22
kcoloredit/kxycolorselector.cpp View File

@@ -23,7 +23,7 @@
23 23
 
24 24
 #include "kxycolorselector.h"
25 25
 
26
-KXYColorSelector::KXYColorSelector(TQWidget *parent, const char *name) : KXYSelector(parent,name) {
26
+KXYColorSelector::KXYColorSelector(TQWidget *tqparent, const char *name) : KXYSelector(tqparent,name) {
27 27
 	setBackgroundMode(NoBackground);
28 28
 	setRange(0, 0, COMPONENT_SELECTION_RESOLUTION - 1, COMPONENT_SELECTION_RESOLUTION - 1);
29 29
 	setType(TYPE_NONE);
@@ -42,7 +42,7 @@ void KXYColorSelector::setType(const int type) {
42 42
 
43 43
 void KXYColorSelector::updateContents() {
44 44
 	drawPalette(&pixmap);
45
-	repaint();
45
+	tqrepaint();
46 46
 }
47 47
 
48 48
 void KXYColorSelector::resizeEvent(TQResizeEvent*) {
@@ -70,9 +70,9 @@ void KXYColorSelector::drawCursor(TQPainter* painter, int x, int y) {
70 70
 	TQColor cursorColor;
71 71
 	if(( 2*color.red() + 4*color.green() + 1*color.blue() )*1.0/
72 72
 		( 2*255 + 4*255 + 1*255 ) > 0.65)
73
-		cursorColor = Qt::black;
73
+		cursorColor = TQt::black;
74 74
 	else
75
-		cursorColor = Qt::white;
75
+		cursorColor = TQt::white;
76 76
 	painter->setPen(TQPen( cursorColor ));
77 77
 	const int lineBegin = 2;
78 78
 	const int lineEnd = 6;
@@ -132,25 +132,25 @@ void KXYColorSelector::setColor(TQColor* const color, const int x, const int y)
132 132
 }
133 133
 
134 134
 TQColor* KXYColorSelector::standardColorsPalette() {
135
-	TQColor* palette = new QColor[STANDARD_PALETTE_SIZE];
135
+	TQColor* palette = new TQColor[STANDARD_PALETTE_SIZE];
136 136
 	int i = 0;
137
-	palette[i++] = Qt::red;
138
-	palette[i++] = Qt::green;
139
-	palette[i++] = Qt::blue;
140
-	palette[i++] = Qt::cyan;
141
-	palette[i++] = Qt::magenta;
142
-	palette[i++] = Qt::yellow;
143
-	palette[i++] = Qt::darkRed;
144
-	palette[i++] = Qt::darkGreen;
145
-	palette[i++] = Qt::darkBlue;
146
-	palette[i++] = Qt::darkCyan;
147
-	palette[i++] = Qt::darkMagenta;
148
-	palette[i++] = Qt::darkYellow;
149
-	palette[i++] = Qt::white;
150
-	palette[i++] = Qt::lightGray;
151
-	palette[i++] = Qt::gray;
152
-	palette[i++] = Qt::darkGray;
153
-	palette[i++] = Qt::black;
137
+	palette[i++] = TQt::red;
138
+	palette[i++] = TQt::green;
139
+	palette[i++] = TQt::blue;
140
+	palette[i++] = TQt::cyan;
141
+	palette[i++] = TQt::magenta;
142
+	palette[i++] = TQt::yellow;
143
+	palette[i++] = TQt::darkRed;
144
+	palette[i++] = TQt::darkGreen;
145
+	palette[i++] = TQt::darkBlue;
146
+	palette[i++] = TQt::darkCyan;
147
+	palette[i++] = TQt::darkMagenta;
148
+	palette[i++] = TQt::darkYellow;
149
+	palette[i++] = TQt::white;
150
+	palette[i++] = TQt::lightGray;
151
+	palette[i++] = TQt::gray;
152
+	palette[i++] = TQt::darkGray;
153
+	palette[i++] = TQt::black;
154 154
 	return palette;
155 155
 }
156 156
 

+ 2
- 1
kcoloredit/kxycolorselector.h View File

@@ -28,6 +28,7 @@
28 28
   */
29 29
 class KXYColorSelector : public KXYSelector  {
30 30
    Q_OBJECT
31
+  TQ_OBJECT
31 32
 
32 33
 public:
33 34
 	/** The types of the selector. They specify a color component subset */
@@ -46,7 +47,7 @@ public:
46 47
 	/** Constructs a two-dimensional color component selector widget,
47 48
 	 *  with a type TYPE_NONE and ranges 0 .. MAX_COLOR_COMPONENT_VALUE
48 49
 	 */
49
-	KXYColorSelector(TQWidget *parent=0, const char *name=0);
50
+	KXYColorSelector(TQWidget *tqparent=0, const char *name=0);
50 51
 	~KXYColorSelector();
51 52
 	/** Set the type of the selector */
52 53
 	void setType(const int type);

+ 21
- 21
kcoloredit/kzcolorselector.cpp View File

@@ -23,8 +23,8 @@
23 23
 #include "main.h"
24 24
 #include "kzcolorselector.h"
25 25
 
26
-KZColorSelector::KZColorSelector(Orientation o, TQWidget *parent, const char *name) :
27
-	KSelector(o, parent, name) {
26
+KZColorSelector::KZColorSelector(Qt::Orientation o, TQWidget *tqparent, const char *name) :
27
+	KSelector(o, tqparent, name) {
28 28
 	baseColorH = -1;
29 29
 	baseColorS = 0;
30 30
 	baseColorV = 0;
@@ -53,7 +53,7 @@ void KZColorSelector::setType(const int type) {
53 53
 
54 54
 void KZColorSelector::updateContents() {
55 55
 	drawPalette(&pixmap);
56
-	repaint(false);
56
+	tqrepaint(false);
57 57
 }
58 58
 
59 59
 void KZColorSelector::resizeEvent(TQResizeEvent*) {
@@ -119,25 +119,25 @@ void KZColorSelector::setColor(TQColor* const color, const int y) {
119 119
 }
120 120
 
121 121
 TQColor* KZColorSelector::getStandardColorsPalette() {
122
-	TQColor* palette = new QColor[( int )STANDARD_PALETTE_SIZE];
122
+	TQColor* palette = new TQColor[( int )STANDARD_PALETTE_SIZE];
123 123
 	int i = 0;
124
-	palette[i++] = Qt::red;
125
-	palette[i++] = Qt::green;
126
-	palette[i++] = Qt::blue;
127
-	palette[i++] = Qt::cyan;
128
-	palette[i++] = Qt::magenta;
129
-	palette[i++] = Qt::yellow;
130
-	palette[i++] = Qt::darkRed;
131
-	palette[i++] = Qt::darkGreen;
132
-	palette[i++] = Qt::darkBlue;
133
-	palette[i++] = Qt::darkCyan;
134
-	palette[i++] = Qt::darkMagenta;
135
-	palette[i++] = Qt::darkYellow;
136
-	palette[i++] = Qt::white;
137
-	palette[i++] = Qt::lightGray;
138
-	palette[i++] = Qt::gray;
139
-	palette[i++] = Qt::darkGray;
140
-	palette[i++] = Qt::black;
124
+	palette[i++] = TQt::red;
125
+	palette[i++] = TQt::green;
126
+	palette[i++] = TQt::blue;
127
+	palette[i++] = TQt::cyan;
128
+	palette[i++] = TQt::magenta;
129
+	palette[i++] = TQt::yellow;
130
+	palette[i++] = TQt::darkRed;
131
+	palette[i++] = TQt::darkGreen;
132
+	palette[i++] = TQt::darkBlue;
133
+	palette[i++] = TQt::darkCyan;
134
+	palette[i++] = TQt::darkMagenta;
135
+	palette[i++] = TQt::darkYellow;
136
+	palette[i++] = TQt::white;
137
+	palette[i++] = TQt::lightGray;
138
+	palette[i++] = TQt::gray;
139
+	palette[i++] = TQt::darkGray;
140
+	palette[i++] = TQt::black;
141 141
 	return palette;
142 142
 }
143 143
 

+ 2
- 1
kcoloredit/kzcolorselector.h View File

@@ -29,6 +29,7 @@
29 29
  */
30 30
 class KZColorSelector : public KSelector {
31 31
    Q_OBJECT
32
+  TQ_OBJECT
32 33
 	
33 34
 public:
34 35
 	/** Selector type constants */
@@ -37,7 +38,7 @@ public:
37 38
 	       TYPE_V = 2 };
38 39
 
39 40
 	/** Constructs the widget */
40
-	KZColorSelector(Orientation o, TQWidget *parent=0, const char *name=0);
41
+	KZColorSelector(Qt::Orientation o, TQWidget *tqparent=0, const char *name=0);
41 42
 	~KZColorSelector();
42 43
 	/** Sets the selector type */
43 44
 	void setType(const int type);

+ 3
- 3
kcoloredit/loadpalettedlg.cpp View File

@@ -31,8 +31,8 @@
31 31
 #include "palette.h"
32 32
 #include "loadpalettedlg.h"
33 33
 
34
-LoadPaletteDlg::LoadPaletteDlg(TQWidget *parent, const char *name) 
35
-        : KDialogBase(parent, name, true, i18n( "Load Palette" ), 
34
+LoadPaletteDlg::LoadPaletteDlg(TQWidget *tqparent, const char *name) 
35
+        : KDialogBase(tqparent, name, true, i18n( "Load Palette" ), 
36 36
           Ok|Cancel, Ok, true) {
37 37
 	fileName = "";
38 38
     TQWidget *mainWidget = new TQWidget( this );
@@ -45,7 +45,7 @@ LoadPaletteDlg::LoadPaletteDlg(TQWidget *parent, const char *name)
45 45
 	TQStringList palettesList = Palette::kdePalettes();
46 46
 	for(TQStringList::Iterator palette = palettesList.begin();
47 47
 		palette != palettesList.end(); ++palette) {
48
-		bool prepend = (*palette).contains( "colors/Custom_Colors" );
48
+		bool prepend = (*palette).tqcontains( "colors/Custom_Colors" );
49 49
 		TQString fileName = locate("config", (*palette));
50 50
 		if(prepend) {
51 51
 			palettesFileNames.prepend(fileName);

+ 2
- 1
kcoloredit/loadpalettedlg.h View File

@@ -27,11 +27,12 @@
27 27
   */
28 28
 class LoadPaletteDlg : public KDialogBase  {
29 29
 	Q_OBJECT
30
+  TQ_OBJECT
30 31
 	
31 32
 public:
32 33
 	/** constructs the dialog
33 34
 	 */
34
-	LoadPaletteDlg(TQWidget *parent = 0, const char *name = 0);
35
+	LoadPaletteDlg(TQWidget *tqparent = 0, const char *name = 0);
35 36
 	~LoadPaletteDlg();
36 37
 	/** @return the fetched file name
37 38
 	 */

+ 4
- 4
kcoloredit/palette.cpp View File

@@ -108,14 +108,14 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
108 108
 	int lineNum = 0;
109 109
 	while (!stream.atEnd()) {
110 110
 		TQString string = stream.readLine().append(' ');
111
-		if(string.find( TQRegExp("[^\\s]") ) == -1 ||
111
+		if(string.tqfind( TQRegExp("[^\\s]") ) == -1 ||
112 112
 			string.stripWhiteSpace().at( 0 ) == '#' ||
113 113
 			( loadName && lineNum == 0 )) {
114 114
 			if(loadName && lineNum == 0)
115 115
 				setName(string.stripWhiteSpace());
116 116
 		} else {
117 117
 			Color* newColor = new Color();
118
-			int position = string.find(TQRegExp( "[^\\s]" ));
118
+			int position = string.tqfind(TQRegExp( "[^\\s]" ));
119 119
 			for(int componentIndex = 0; componentIndex < Color::COMPONENTS_NUM;
120 120
 				++componentIndex) {
121 121
 				if(position == -1) {
@@ -123,7 +123,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
123 123
 					result = false;
124 124
 					break;
125 125
 				}
126
-				int endPosition = string.find(TQRegExp( "\\s" ), position);
126
+				int endPosition = string.tqfind(TQRegExp( "\\s" ), position);
127 127
 				if(endPosition == -1) {
128 128
 					m_errorString = i18n("Invalid format");
129 129
 					result = false;
@@ -139,7 +139,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
139 139
 					break;
140 140
 				}
141 141
 				newColor->setComponent(componentIndex, componentValue);
142
-				position = string.find(TQRegExp( "[^\\s]" ), endPosition);
142
+				position = string.tqfind(TQRegExp( "[^\\s]" ), endPosition);
143 143
 			}
144 144
 			if(!result) {
145 145
 				delete newColor;

+ 3
- 3
kcoloredit/paletteview.cpp View File

@@ -21,8 +21,8 @@
21 21
 #include "paletteview.h"
22 22
 
23 23
 PaletteView::PaletteView(const int defaultCellWidth, const int defaultCellHeight, const int cellSpacing,
24
-	KColorEditView* view, TQWidget *parent, const char *name) :
25
-	TQFrame(parent, name, TQWidget::WResizeNoErase*0) {
24
+	KColorEditView* view, TQWidget *tqparent, const char *name) :
25
+	TQFrame(tqparent, name, TQWidget::WResizeNoErase*0) {
26 26
 	setFrameStyle(StyledPanel|Sunken);
27 27
 	setLineWidth(2);
28 28
 	TQGridLayout* topLayout = new TQGridLayout(this, 2, 2);
@@ -32,7 +32,7 @@ PaletteView::PaletteView(const int defaultCellWidth, const int defaultCellHeight
32 32
 	topLayout->setColStretch(0, 10);
33 33
 	topLayout->setColStretch(1, 0);
34 34
 	scrollBar = new TQScrollBar(this);
35
-	hScrollBar = new TQScrollBar(0, 1, 1, 1, 0, TQScrollBar::Horizontal, this);
35
+	hScrollBar = new TQScrollBar(0, 1, 1, 1, 0, Qt::Horizontal, this);
36 36
 	scrolledArea = new PaletteViewScrolledArea(defaultCellWidth,
37 37
 		defaultCellHeight, cellSpacing, scrollBar, hScrollBar, view, this);
38 38
 	connect(scrollBar, TQT_SIGNAL( valueChanged(int) ),

+ 3
- 2
kcoloredit/paletteview.h View File

@@ -26,18 +26,19 @@
26 26
 class KColorEditView;
27 27
 
28 28
 /** This is a Palette class view widget.
29
-  * Its parent is KColorEditView
29
+  * Its tqparent is KColorEditView
30 30
   * @author Artur Rataj
31 31
   */
32 32
 class PaletteView : public TQFrame {
33 33
 	Q_OBJECT
34
+  TQ_OBJECT
34 35
 
35 36
 public:
36 37
 	/** Constructs a palette view widget, with a default cells sizes and spacing.
37 38
 	 *  The effective cell sizes may be adjusted to fit the widget sizes.
38 39
 	 */
39 40
 	PaletteView(const int defaultCellWidth, const int defaultCellHeight, const int cellSpacing,
40
-			KColorEditView* view, TQWidget *parent = 0, const char *name=0);
41
+			KColorEditView* view, TQWidget *tqparent = 0, const char *name=0);
41 42
 	~PaletteView();
42 43
 	/** Calls redraw() in scrolledArea */
43 44
 	void redraw();

+ 12
- 12
kcoloredit/paletteviewscrolledarea.cpp View File

@@ -38,8 +38,8 @@
38 38
 
39 39
 PaletteViewScrolledArea::PaletteViewScrolledArea(const int defaultCellWidth,
40 40
 	const int defaultCellHeight, const int cellSpacing, TQScrollBar* scrollBar,
41
-	TQScrollBar* hScrollBar, KColorEditView* view, TQWidget* parent, const char* name)
42
-	: TQFrame(parent, name) {
41
+	TQScrollBar* hScrollBar, KColorEditView* view, TQWidget* tqparent, const char* name)
42
+	: TQFrame(tqparent, name) {
43 43
 	this->defaultCellWidth = defaultCellWidth;
44 44
 	this->defaultCellHeight = defaultCellHeight;
45 45
 	this->cellSpacing = cellSpacing;
@@ -73,11 +73,11 @@ void PaletteViewScrolledArea::slotViewColorNames(bool viewColorNames) {
73 73
 
74 74
 void PaletteViewScrolledArea::redraw() {
75 75
 	//setCellsSizes();
76
-	repaintPalette();
76
+	tqrepaintPalette();
77 77
 }
78 78
 
79
-void PaletteViewScrolledArea::repaintPalette() {
80
-	repaint(false);
79
+void PaletteViewScrolledArea::tqrepaintPalette() {
80
+	tqrepaint(false);
81 81
 }
82 82
 
83 83
 void PaletteViewScrolledArea::checkSelectionAutoScroll(const int mousePosY) {
@@ -106,7 +106,7 @@ void PaletteViewScrolledArea::slotScrollTimeout() {
106 106
 		else
107 107
 			setSelection(selectionEnd, selectionBegin);
108 108
 		checkSelectionAutoScroll(cursorPoint.y());
109
-		repaintPalette();
109
+		tqrepaintPalette();
110 110
 	}
111 111
 }
112 112
 
@@ -220,7 +220,7 @@ void PaletteViewScrolledArea::paintEvent(TQPaintEvent* /*event*/) {
220 220
 	setCellsSizes();
221 221
 	TQPixmap pixmap(size());
222 222
 	TQPainter painter;
223
-	painter.begin(&pixmap, this);
223
+	painter.tqbegin(TQT_TQPAINTDEVICE(&pixmap), this);
224 224
 	TQFontMetrics fontMetrics = painter.fontMetrics();
225 225
 	int maxLineWidth;
226 226
 	if(viewColorNames) {
@@ -249,12 +249,12 @@ void PaletteViewScrolledArea::paintEvent(TQPaintEvent* /*event*/) {
249 249
 	int lastRow = (posY + height() - 1 + rowHeight - 1)/rowHeight;
250 250
 	if(viewColorNames)
251 251
 		painter.fillRect(0, 0, rowWidth, height(),
252
-        TQBrush( TQFrame::palette().active().base() ));
253
-	TQBrush normalBackgroundBrush(TQFrame::palette().active().background());
254
-	TQBrush selectedBackgroundBrush(TQFrame::palette().active().highlight());
252
+        TQBrush( TQFrame::tqpalette().active().base() ));
253
+	TQBrush normalBackgroundBrush(TQFrame::tqpalette().active().background());
254
+	TQBrush selectedBackgroundBrush(TQFrame::tqpalette().active().highlight());
255 255
 	TQBrush foregroundBrush;
256
-	TQBrush cursorBrush(TQFrame::palette().active().foreground());
257
-	TQPen backgroundPen(TQFrame::palette().active().foreground());
256
+	TQBrush cursorBrush(TQFrame::tqpalette().active().foreground());
257
+	TQPen backgroundPen(TQFrame::tqpalette().active().foreground());
258 258
 	int min = selectionMin();
259 259
 	int max = selectionMax();
260 260
 	int fontAscent = fontMetrics.ascent();

+ 5
- 4
kcoloredit/paletteviewscrolledarea.h View File

@@ -33,15 +33,16 @@ class TQScrollBar;
33 33
  */
34 34
 class PaletteViewScrolledArea : public TQFrame {
35 35
 	Q_OBJECT
36
+  TQ_OBJECT
36 37
 
37 38
 public:
38 39
 	/** Constructs the widget */
39 40
 	PaletteViewScrolledArea(const int defaultCellWidth, const int defaultCellHeight,
40 41
 		const int cellSpacing, TQScrollBar* scrollBar,
41 42
 		TQScrollBar* hScrollBar, KColorEditView* view,
42
-		TQWidget* parent = 0, const char* name = 0);
43
+		TQWidget* tqparent = 0, const char* name = 0);
43 44
 	~PaletteViewScrolledArea();
44
-	/** Sets cells sizes and then calls repaintPalette() */
45
+	/** Sets cells sizes and then calls tqrepaintPalette() */
45 46
 	void redraw();
46 47
 
47 48
 public slots:
@@ -105,8 +106,8 @@ protected:
105 106
 	 *  visible area width
106 107
 	 */
107 108
 	void setCellsSizes();
108
-	/** repaints the palette */
109
-	void repaintPalette();
109
+	/** tqrepaints the palette */
110
+	void tqrepaintPalette();
110 111
 	/** @return A color index at a given position, -1 if none */
111 112
 	int colorIndex(const TQPoint& point) const;
112 113
 	/** @return A color at a given position */

+ 5
- 5
kcoloredit/texteditselection.cpp View File

@@ -24,7 +24,7 @@
24 24
 #include "main.h"
25 25
 #include "texteditselection.h"
26 26
 
27
-TextEditSelection::TextEditSelection(TQWidget *parent, const char *name ) : TQWidget(parent,name) {
27
+TextEditSelection::TextEditSelection(TQWidget *tqparent, const char *name ) : TQWidget(tqparent,name) {
28 28
 	inChangingComponents = false;
29 29
 	TQVBoxLayout* topLayout = new TQVBoxLayout(this, 4);
30 30
 	TQGridLayout* componentsLayout = new TQGridLayout(3, 5, 2);
@@ -59,14 +59,14 @@ TextEditSelection::~TextEditSelection(){
59 59
 }
60 60
 
61 61
 void TextEditSelection::addComponent(const int index, TQLineEdit* lineEdit, const int maxValue,
62
-	const TQString& labelString, const int row, const int column, TQGridLayout* layout) {
62
+	const TQString& labelString, const int row, const int column, TQGridLayout* tqlayout) {
63 63
 	TQLabel* label = new TQLabel(labelString, this);
64
-	lineEdit->setValidator(new TQIntValidator( 0, maxValue, lineEdit ));
64
+	lineEdit->setValidator(new TQIntValidator( 0, maxValue, TQT_TQOBJECT(lineEdit) ));
65 65
 	lineEditTable[index] = lineEdit;
66 66
 	lineEdit->setMinimumWidth(lineEdit->fontMetrics().width( TQString("8888") ));
67 67
 	lineEdit->setMaximumWidth(lineEdit->fontMetrics().width( TQString("8888888") ));
68
-	layout->addWidget(label, row, column*3);
69
-	layout->addWidget(lineEdit, row, column*3 + 1);
68
+	tqlayout->addWidget(label, row, column*3);
69
+	tqlayout->addWidget(lineEdit, row, column*3 + 1);
70 70
 }
71 71
 
72 72
 void TextEditSelection::setRgbString(const int red, const int green, const int blue) {

+ 3
- 2
kcoloredit/texteditselection.h View File

@@ -30,10 +30,11 @@
30 30
   */
31 31
 class TextEditSelection : public TQWidget  {
32 32
    Q_OBJECT
33
+  TQ_OBJECT
33 34
 
34 35
 public:
35 36
 	/** Constructs the widget */
36
-	TextEditSelection(TQWidget *parent=0, const char *name=0);
37
+	TextEditSelection(TQWidget *tqparent=0, const char *name=0);
37 38
 	~TextEditSelection();
38 39
 	
39 40
 signals:
@@ -47,7 +48,7 @@ public slots:
47 48
 protected:
48 49
 	/** Adds a component line edit */
49 50
 	void addComponent(const int index, TQLineEdit* lineEdit, const int maxValue, const TQString& labelString,
50
-		const int row, const int column, TQGridLayout* layout);
51
+		const int row, const int column, TQGridLayout* tqlayout);
51 52
 	/** sets RGB string in rgbStringLineEdit */
52 53
 	void setRgbString(const int red, const int green, const int blue);
53 54
 		

+ 1
- 1
kcoloredit/textselection.cpp View File

@@ -17,7 +17,7 @@
17 17
 
18 18
 #include "textselection.h"
19 19
 
20
-TextSelection::TextSelection(TQWidget *parent, const char *name ) : TQWidget(parent,name) {
20
+TextSelection::TextSelection(TQWidget *tqparent, const char *name ) : TQWidget(tqparent,name) {
21 21
 	
22 22
 }
23 23
 TextSelection::~TextSelection(){

+ 5
- 5
kdvi/TeXFont.h View File

@@ -17,8 +17,8 @@ class TeXFont {
17 17
  public:
18 18
   TeXFont(TeXFontDefinition *_parent)
19 19
     {
20
-      parent       = _parent;
21
-      errorMessage = TQString::null;
20
+      tqparent       = _parent;
21
+      errorMessage = TQString();
22 22
     };
23 23
   
24 24
   virtual ~TeXFont();
@@ -29,12 +29,12 @@ class TeXFont {
29 29
 	glyphtable[i].shrunkenCharacter.resize(0, 0);
30 30
     };
31 31
   
32
-  virtual glyph* getGlyph(Q_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=Qt::black) = 0;
32
+  virtual glyph* getGlyph(TQ_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=TQt::black) = 0;
33 33
 
34 34
   // Checksum of the font. Used e.g. by PK fonts. This field is filled
35 35
   // in by the constructor, or set to 0.0, if the font format does not
36 36
   // contain checksums.
37
-  Q_UINT32           checksum;
37
+  TQ_UINT32           checksum;
38 38
 
39 39
   // If the font or if some glyphs could not be loaded, error messages
40 40
   // will be put here.
@@ -42,7 +42,7 @@ class TeXFont {
42 42
    
43 43
  protected:
44 44
   glyph              glyphtable[TeXFontDefinition::max_num_of_chars_in_font];
45
-  TeXFontDefinition *parent;
45
+  TeXFontDefinition *tqparent;
46 46
 };
47 47
 
48 48
 #endif

+ 8
- 8
kdvi/TeXFontDefinition.cpp View File

@@ -31,7 +31,7 @@ extern const int MFResolutions[];
31 31
 // #define DEBUG_FONT
32 32
 
33 33
 
34
-TeXFontDefinition::TeXFontDefinition(TQString nfontname, double _displayResolution_in_dpi, Q_UINT32 chk, Q_INT32 _scaled_size_in_DVI_units,
34
+TeXFontDefinition::TeXFontDefinition(TQString nfontname, double _displayResolution_in_dpi, TQ_UINT32 chk, TQ_INT32 _scaled_size_in_DVI_units,
35 35
 	   class fontPool *pool, double _enlargement)
36 36
 {
37 37
 #ifdef DEBUG_FONT
@@ -46,7 +46,7 @@ TeXFontDefinition::TeXFontDefinition(TQString nfontname, double _displayResoluti
46 46
   checksum                 = chk;
47 47
   flags                    = TeXFontDefinition::FONT_IN_USE;
48 48
   file                     = 0; 
49
-  filename                 = TQString::null;
49
+  filename                 = TQString();
50 50
   scaled_size_in_DVI_units = _scaled_size_in_DVI_units;
51 51
   
52 52
   macrotable               = 0;
@@ -93,8 +93,8 @@ void TeXFontDefinition::fontNameReceiver(const TQString& fname)
93 93
   flags |= TeXFontDefinition::FONT_LOADED;
94 94
   filename = fname;
95 95
 #ifdef HAVE_FREETYPE
96
-  fullFontName = TQString::null;
97
-  fullEncodingName = TQString::null;
96
+  fullFontName = TQString();
97
+  fullEncodingName = TQString();
98 98
 #endif
99 99
 
100 100
   file = fopen(TQFile::encodeName(filename), "r");
@@ -105,7 +105,7 @@ void TeXFontDefinition::fontNameReceiver(const TQString& fname)
105 105
     TQString filename_test(font_pool->getExtraSearchPath() + "/" + filename);
106 106
     file = fopen( TQFile::encodeName(filename_test), "r");
107 107
     if (file == 0) {
108
-      kdError(4300) << i18n("Cannot find font %1, file %2.").arg(fontname).arg(filename) << endl;
108
+      kdError(4300) << i18n("Cannot find font %1, file %2.").tqarg(fontname).tqarg(filename) << endl;
109 109
       return;
110 110
     } else
111 111
       filename = filename_test;
@@ -121,7 +121,7 @@ void TeXFontDefinition::fontNameReceiver(const TQString& fname)
121 121
       font = new TeXFont_PK(this);
122 122
       set_char_p = &dviRenderer::set_char;
123 123
       if ((checksum != 0) && (checksum != font->checksum)) 
124
-	kdWarning(4300) << i18n("Checksum mismatch for font file %1").arg(filename) << endl;
124
+	kdWarning(4300) << i18n("Checksum mismatch for font file %1").tqarg(filename) << endl;
125 125
       fontTypeName = "TeX PK";
126 126
       return;
127 127
     }
@@ -169,7 +169,7 @@ void TeXFontDefinition::fontNameReceiver(const TQString& fname)
169 169
 #else
170 170
   // If we don't have the FreeType library, we should never have
171 171
   // reached this point. Complain, and leave this font blank
172
-  kdError(4300) << i18n("Cannot recognize format for font file %1").arg(filename) << endl;
172
+  kdError(4300) << i18n("Cannot recognize format for font file %1").tqarg(filename) << endl;
173 173
 #endif
174 174
 }
175 175
 
@@ -195,7 +195,7 @@ void TeXFontDefinition::reset()
195 195
       vf_table.clear();
196 196
   }
197 197
   
198
-  filename   = TQString::null;
198
+  filename   = TQString();
199 199
   flags      = TeXFontDefinition::FONT_IN_USE;
200 200
   set_char_p = &dviRenderer::set_empty_char;
201 201
 }

+ 7
- 7
kdvi/TeXFontDefinition.h View File

@@ -1,6 +1,6 @@
1 1
 // -*- C++ -*-
2 2
 /*
3
- * The layout of a font information block.
3
+ * The tqlayout of a font information block.
4 4
  * There is one of these for every loaded font or magnification thereof.
5 5
  * Duplicates are eliminated:  this is necessary because of possible recursion
6 6
  * in virtual fonts.
@@ -35,7 +35,7 @@ class macro {
35 35
 
36 36
   unsigned char	*pos;		/* address of first byte of macro */
37 37
   unsigned char	*end;		/* address of last+1 byte */
38
-  Q_INT32        dvi_advance_in_units_of_design_size_by_2e20;	/* DVI units to move reference point */
38
+  TQ_INT32        dvi_advance_in_units_of_design_size_by_2e20;	/* DVI units to move reference point */
39 39
   bool          free_me;        // if memory at pos should be returned on destruction
40 40
 };
41 41
 
@@ -56,7 +56,7 @@ class TeXFontDefinition {
56 56
   };
57 57
   
58 58
 
59
-  TeXFontDefinition(TQString nfontname, double _displayResolution_in_dpi, Q_UINT32 chk, Q_INT32 _scaled_size_in_DVI_units,
59
+  TeXFontDefinition(TQString nfontname, double _displayResolution_in_dpi, TQ_UINT32 chk, TQ_INT32 _scaled_size_in_DVI_units,
60 60
        class fontPool *pool, double _enlargement);
61 61
   ~TeXFontDefinition();
62 62
 
@@ -74,7 +74,7 @@ class TeXFontDefinition {
74 74
   TQString        fontname;	// name of font, such as "cmr10"
75 75
   unsigned char  flags;		// flags byte (see values below)
76 76
   double         enlargement;
77
-  Q_INT32        scaled_size_in_DVI_units;   // Scaled size from the font definition command; in DVI units
77
+  TQ_INT32        scaled_size_in_DVI_units;   // Scaled size from the font definition command; in DVI units
78 78
   set_char_proc  set_char_p;	// proc used to set char
79 79
   
80 80
   // Resolution of the display device (resolution will usually be
@@ -100,20 +100,20 @@ class TeXFontDefinition {
100 100
   /** For FREETYPE fonts, which use a map file, this field will
101 101
       contain the full name of the font (e.g. 'Computer Modern'). If
102 102
       the name does not exist, or cannot be found, this field will be
103
-      TQString::null. Only subclasses of TeXFont should write into this
103
+      TQString(). Only subclasses of TeXFont should write into this
104 104
       field. */
105 105
   TQString        fullFontName;
106 106
 
107 107
   /** For FREETYPE fonts, which use a map file, this field will
108 108
       contain the full name of the font encoding (e.g. 'TexBase1'). If
109 109
       the encoding name does not exist, or cannot be found, this field
110
-      will be TQString::null. Only subclasses of TeXFont should write
110
+      will be TQString(). Only subclasses of TeXFont should write
111 111
       into this field. */
112 112
   TQString        fullEncodingName;
113 113
 #endif
114 114
 
115 115
  private:
116
-  Q_UINT32       checksum;
116
+  TQ_UINT32       checksum;
117 117
 
118 118
   /** This will be set to a human-readable description of the font,
119 119
       e.g. "virtual" or "TeX PK", or "Type 1" */

+ 32
- 32
kdvi/TeXFont_PFB.cpp View File

@@ -26,28 +26,28 @@
26 26
 //#define DEBUG_PFB 1
27 27
 
28 28
 
29
-TeXFont_PFB::TeXFont_PFB(TeXFontDefinition *parent, fontEncoding *enc, double slant)
30
-  : TeXFont(parent)
29
+TeXFont_PFB::TeXFont_PFB(TeXFontDefinition *tqparent, fontEncoding *enc, double slant)
30
+  : TeXFont(tqparent)
31 31
 {
32 32
 #ifdef DEBUG_PFB
33 33
   if (enc != 0)
34
-    kdDebug(4300) << "TeXFont_PFB::TeXFont_PFB( parent=" << parent << ", encoding=" << enc->encodingFullName << " )" << endl;
34
+    kdDebug(4300) << "TeXFont_PFB::TeXFont_PFB( tqparent=" << tqparent << ", encoding=" << enc->encodingFullName << " )" << endl;
35 35
   else
36
-    kdDebug(4300) << "TeXFont_PFB::TeXFont_PFB( parent=" << parent << ", encoding=0 )" << endl;
36
+    kdDebug(4300) << "TeXFont_PFB::TeXFont_PFB( tqparent=" << tqparent << ", encoding=0 )" << endl;
37 37
 #endif
38 38
 
39 39
   fatalErrorInFontLoading = false;
40 40
 
41
-  int error = FT_New_Face( parent->font_pool->FreeType_library, parent->filename.local8Bit(), 0, &face );
41
+  int error = FT_New_Face( tqparent->font_pool->FreeType_library, tqparent->filename.local8Bit(), 0, &face );
42 42
   
43 43
   if ( error == FT_Err_Unknown_File_Format ) {
44
-    errorMessage = i18n("The font file %1 could be opened and read, but its font format is unsupported.").arg(parent->filename);
44
+    errorMessage = i18n("The font file %1 could be opened and read, but its font format is unsupported.").tqarg(tqparent->filename);
45 45
     kdError(4300) << errorMessage << endl;
46 46
     fatalErrorInFontLoading = true;
47 47
     return;
48 48
   } else 
49 49
     if ( error ) {
50
-      errorMessage = i18n("The font file %1 is broken, or it could not be opened or read.").arg(parent->filename);
50
+      errorMessage = i18n("The font file %1 is broken, or it could not be opened or read.").tqarg(tqparent->filename);
51 51
       kdError(4300) << errorMessage << endl;
52 52
       fatalErrorInFontLoading = true;
53 53
       return;
@@ -66,7 +66,7 @@ TeXFont_PFB::TeXFont_PFB(TeXFontDefinition *parent, fontEncoding *enc, double sl
66 66
   }
67 67
   
68 68
   if (face->family_name != 0)
69
-    parent->fullFontName = face->family_name;
69
+    tqparent->fullFontName = face->family_name;
70 70
 
71 71
   // Finally, we need to set up the charMap array, which maps TeX
72 72
   // character codes to glyph indices in the font. (Remark: the
@@ -74,8 +74,8 @@ TeXFont_PFB::TeXFont_PFB(TeXFontDefinition *parent, fontEncoding *enc, double sl
74 74
   // TeX is only able to address character codes 0-255 while
75 75
   // e.g. Type1 fonts may contain several thousands of characters)
76 76
   if (enc != 0) {
77
-    parent->fullEncodingName = enc->encodingFullName.remove(TQString::fromLatin1( "Encoding" ));
78
-    parent->fullEncodingName = enc->encodingFullName.remove(TQString::fromLatin1( "encoding" ));
77
+    tqparent->fullEncodingName = enc->encodingFullName.remove(TQString::tqfromLatin1( "Encoding" ));
78
+    tqparent->fullEncodingName = enc->encodingFullName.remove(TQString::tqfromLatin1( "encoding" ));
79 79
 
80 80
     // An encoding vector is given for this font, i.e. an array of
81 81
     // character names (such as: 'parenleft' or 'dotlessj'). We use
@@ -138,7 +138,7 @@ TeXFont_PFB::~TeXFont_PFB()
138 138
 }
139 139
 
140 140
 
141
-glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQColor& color)
141
+glyph *TeXFont_PFB::getGlyph(TQ_UINT16 ch, bool generateCharacterPixmap, const TQColor& color)
142 142
 {
143 143
 #ifdef DEBUG_PFB
144 144
   kdDebug(4300) << "TeXFont_PFB::getGlyph( ch=" << ch << ", '" << (char)(ch) << "', generateCharacterPixmap=" << generateCharacterPixmap << " )" << endl;
@@ -159,16 +159,16 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
159 159
   
160 160
   if ((generateCharacterPixmap == true) && ((g->shrunkenCharacter.isNull()) || (color != g->color)) ) {
161 161
     int error;
162
-    unsigned int res =  (unsigned int)(parent->displayResolution_in_dpi/parent->enlargement +0.5);
162
+    unsigned int res =  (unsigned int)(tqparent->displayResolution_in_dpi/tqparent->enlargement +0.5);
163 163
     g->color = color;
164 164
 
165 165
     // Character height in 1/64th of points (reminder: 1 pt = 1/72 inch)
166 166
     // Only approximate, may vary from file to file!!!! @@@@@
167 167
 
168
-    long int characterSize_in_printers_points_by_64 = (long int)((64.0*72.0*parent->scaled_size_in_DVI_units*parent->font_pool->getCMperDVIunit())/2.54 + 0.5 ); 
168
+    long int characterSize_in_printers_points_by_64 = (long int)((64.0*72.0*tqparent->scaled_size_in_DVI_units*tqparent->font_pool->getCMperDVIunit())/2.54 + 0.5 ); 
169 169
     error = FT_Set_Char_Size(face, 0, characterSize_in_printers_points_by_64, res, res );
170 170
     if (error) {
171
-      TQString msg = i18n("FreeType reported an error when setting the character size for font file %1.").arg(parent->filename);
171
+      TQString msg = i18n("FreeType reported an error when setting the character size for font file %1.").tqarg(tqparent->filename);
172 172
       if (errorMessage.isEmpty())
173 173
 	errorMessage = msg;
174 174
       kdError(4300) << msg << endl;
@@ -178,13 +178,13 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
178 178
     }
179 179
     
180 180
     // load glyph image into the slot and erase the previous one
181
-    if (parent->font_pool->getUseFontHints() == true)
181
+    if (tqparent->font_pool->getUseFontHints() == true)
182 182
       error = FT_Load_Glyph(face, charMap[ch], FT_LOAD_DEFAULT ); 
183 183
     else
184 184
       error = FT_Load_Glyph(face, charMap[ch], FT_LOAD_NO_HINTING );
185 185
 
186 186
     if (error) {
187
-      TQString msg = i18n("FreeType is unable to load glyph #%1 from font file %2.").arg(ch).arg(parent->filename);
187
+      TQString msg = i18n("FreeType is unable to load glyph #%1 from font file %2.").tqarg(ch).tqarg(tqparent->filename);
188 188
       if (errorMessage.isEmpty())
189 189
 	errorMessage = msg;
190 190
       kdError(4300) << msg << endl;
@@ -196,7 +196,7 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
196 196
     // convert to an anti-aliased bitmap
197 197
     error = FT_Render_Glyph( face->glyph, ft_render_mode_normal );
198 198
     if (error) {
199
-      TQString msg = i18n("FreeType is unable to render glyph #%1 from font file %2.").arg(ch).arg(parent->filename);
199
+      TQString msg = i18n("FreeType is unable to render glyph #%1 from font file %2.").tqarg(ch).tqarg(tqparent->filename);
200 200
       if (errorMessage.isEmpty())
201 201
 	errorMessage = msg;
202 202
       kdError(4300) << msg << endl;
@@ -209,8 +209,8 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
209 209
 
210 210
     if ((slot->bitmap.width == 0) || (slot->bitmap.rows == 0)) {
211 211
       if (errorMessage.isEmpty())
212
-	errorMessage = i18n("Glyph #%1 is empty.").arg(ch);
213
-      kdError(4300) << i18n("Glyph #%1 from font file %2 is empty.").arg(ch).arg(parent->filename) << endl;
212
+	errorMessage = i18n("Glyph #%1 is empty.").tqarg(ch);
213
+      kdError(4300) << i18n("Glyph #%1 from font file %2 is empty.").tqarg(ch).tqarg(tqparent->filename) << endl;
214 214
       g->shrunkenCharacter.resize( 15, 15 );
215 215
       g->shrunkenCharacter.fill(TQColor(255, 0, 0));
216 216
       g->x2 = 0;
@@ -219,9 +219,9 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
219 219
       TQImage imgi(slot->bitmap.width, slot->bitmap.rows, 32);
220 220
       imgi.setAlphaBuffer(true);
221 221
 
222
-      // Do QPixmaps fully support the alpha channel? If yes, we use
222
+      // Do TQPixmaps fully support the alpha channel? If yes, we use
223 223
       // that. Otherwise, use other routines as a fallback
224
-      if (parent->font_pool->QPixmapSupportsAlpha) {
224
+      if (tqparent->font_pool->TQPixmapSupportsAlpha) {
225 225
 	// If the alpha channel is properly supported, we set the
226 226
 	// character glyph to a colored rectangle, and define the
227 227
 	// character outline only using the alpha channel. That
@@ -239,7 +239,7 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
239 239
 	}
240 240
       } else {
241 241
 	// If the alpha channel is not supported... QT seems to turn
242
-	// the alpha channel into a crude bitmap which is used to mask
242
+	// the alpha channel into a crude bitmap which is used to tqmask
243 243
 	// the resulting TQPixmap. In this case, we define the
244 244
 	// character outline using the image data, and use the alpha
245 245
 	// channel only to store "maximally opaque" or "completely
@@ -248,18 +248,18 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
248 248
 	// quality is still sufficient for most purposes. One notable
249 249
 	// exception is output from the gftodvi program, which will be
250 250
 	// partially unreadable.
251
-	Q_UINT16 rInv = 0xFF - color.red();
252
-	Q_UINT16 gInv = 0xFF - color.green();
253
-	Q_UINT16 bInv = 0xFF - color.blue();
251
+	TQ_UINT16 rInv = 0xFF - color.red();
252
+	TQ_UINT16 gInv = 0xFF - color.green();
253
+	TQ_UINT16 bInv = 0xFF - color.blue();
254 254
 	
255
-	for(Q_UINT16 y=0; y<slot->bitmap.rows; y++) {
256
-	  Q_UINT8 *srcScanLine = slot->bitmap.buffer + y*slot->bitmap.pitch;
255
+	for(TQ_UINT16 y=0; y<slot->bitmap.rows; y++) {
256
+	  TQ_UINT8 *srcScanLine = slot->bitmap.buffer + y*slot->bitmap.pitch;
257 257
 	  unsigned int *destScanLine = (unsigned int *)imgi.scanLine(y);
258
-	  for(Q_UINT16 col=0; col<slot->bitmap.width; col++) {
259
-	    Q_UINT16 data =  *srcScanLine;
258
+	  for(TQ_UINT16 col=0; col<slot->bitmap.width; col++) {
259
+	    TQ_UINT16 data =  *srcScanLine;
260 260
 	    // The value stored in "data" now has the following meaning:
261 261
 	    // data = 0 -> white; data = 0xff -> use "color"
262
-	    *destScanLine = qRgba(0xFF - (rInv*data + 0x7F) / 0xFF,
262
+	    *destScanLine = tqRgba(0xFF - (rInv*data + 0x7F) / 0xFF,
263 263
 				  0xFF - (gInv*data + 0x7F) / 0xFF,
264 264
 				  0xFF - (bInv*data + 0x7F) / 0xFF,
265 265
 				  (data > 0x03) ? 0xff : 0x00);
@@ -279,13 +279,13 @@ glyph *TeXFont_PFB::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQ
279 279
   if (g->dvi_advance_in_units_of_design_size_by_2e20 == 0) {
280 280
     int error = FT_Load_Glyph(face, charMap[ch], FT_LOAD_NO_SCALE);
281 281
     if (error) {
282
-      TQString msg = i18n("FreeType is unable to load metric for glyph #%1 from font file %2.").arg(ch).arg(parent->filename);
282
+      TQString msg = i18n("FreeType is unable to load metric for glyph #%1 from font file %2.").tqarg(ch).tqarg(tqparent->filename);
283 283
       if (errorMessage.isEmpty())
284 284
 	errorMessage = msg;
285 285
       kdError(4300) << msg << endl;
286 286
       g->dvi_advance_in_units_of_design_size_by_2e20 =  1;
287 287
     }
288
-    g->dvi_advance_in_units_of_design_size_by_2e20 =  (Q_INT32)(((Q_INT64)(1<<20) * (Q_INT64)face->glyph->metrics.horiAdvance) / (Q_INT64)face->units_per_EM);
288
+    g->dvi_advance_in_units_of_design_size_by_2e20 =  (TQ_INT32)(((TQ_INT64)(1<<20) * (TQ_INT64)face->glyph->metrics.horiAdvance) / (TQ_INT64)face->units_per_EM);
289 289
   }
290 290
   
291 291
   return g;

+ 3
- 3
kdvi/TeXFont_PFB.h View File

@@ -23,15 +23,15 @@ class glyph;
23 23
 
24 24
 class TeXFont_PFB : public TeXFont {
25 25
  public:
26
-  TeXFont_PFB(TeXFontDefinition *parent, fontEncoding *enc=0, double slant=0.0 );
26
+  TeXFont_PFB(TeXFontDefinition *tqparent, fontEncoding *enc=0, double slant=0.0 );
27 27
   ~TeXFont_PFB();
28 28
   
29
-  glyph* getGlyph(Q_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=Qt::black);
29
+  glyph* getGlyph(TQ_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=TQt::black);
30 30
 
31 31
  private:
32 32
   FT_Face       face;
33 33
   bool          fatalErrorInFontLoading;
34
-  Q_UINT16      charMap[256];
34
+  TQ_UINT16      charMap[256];
35 35
 
36 36
   // This matrix is used internally to describes the slant, if
37 37
   // nonzero. Otherwise, this is undefined.

+ 53
- 53
kdvi/TeXFont_PK.cpp View File

@@ -80,18 +80,18 @@ extern void oops(TQString message);
80 80
 
81 81
 
82 82
 
83
-TeXFont_PK::TeXFont_PK(TeXFontDefinition *parent)
84
-  : TeXFont(parent)
83
+TeXFont_PK::TeXFont_PK(TeXFontDefinition *tqparent)
84
+  : TeXFont(tqparent)
85 85
 {
86 86
 #ifdef DEBUG_PK
87
-  kdDebug(4300) << "TeXFont_PK::TeXFont_PK( parent=" << parent << ")" << endl;
87
+  kdDebug(4300) << "TeXFont_PK::TeXFont_PK( tqparent=" << tqparent << ")" << endl;
88 88
 #endif
89 89
 
90 90
   for(unsigned int i=0; i<TeXFontDefinition::max_num_of_chars_in_font; i++)
91 91
     characterBitmaps[i] = 0;
92
-  file = fopen(TQFile::encodeName(parent->filename), "r");
92
+  file = fopen(TQFile::encodeName(tqparent->filename), "r");
93 93
   if (file == 0) 
94
-    kdError(4300) << i18n("Cannot open font file %1.").arg(parent->filename) << endl;
94
+    kdError(4300) << i18n("Cannot open font file %1.").tqarg(tqparent->filename) << endl;
95 95
 #ifdef DEBUG_PK
96 96
   else
97 97
     kdDebug(4300) << "TeXFont_PK::TeXFont_PK(): file opened successfully" << endl;
@@ -116,7 +116,7 @@ TeXFont_PK::~TeXFont_PK()
116 116
 }
117 117
 
118 118
 
119
-glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQColor& color)
119
+glyph* TeXFont_PK::getGlyph(TQ_UINT16 ch, bool generateCharacterPixmap, const TQColor& color)
120 120
 {
121 121
 #ifdef DEBUG_PK
122 122
   kdDebug(4300) << "TeXFont_PK::getGlyph( ch=" << ch << ", generateCharacterPixmap=" << generateCharacterPixmap << " )" << endl;
@@ -136,7 +136,7 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
136 136
     // If the character is not defined in the PK file, mark the
137 137
     // character as missing, and print an error message
138 138
     if (g->addr == 0) {
139
-      kdError(4300) << i18n("TexFont_PK::operator[]: Character %1 not defined in font %2").arg(ch).arg(parent->filename) << endl;
139
+      kdError(4300) << i18n("TexFont_PK::operator[]: Character %1 not defined in font %2").tqarg(ch).tqarg(tqparent->filename) << endl;
140 140
       g->addr = -1;
141 141
       return g;
142 142
     }
@@ -163,7 +163,7 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
163 163
       ((g->shrunkenCharacter.isNull()) || (color != g->color)) &&
164 164
       (characterBitmaps[ch]->w != 0)) {
165 165
     g->color = color;
166
-    double shrinkFactor = 1200 / parent->displayResolution_in_dpi;
166
+    double shrinkFactor = 1200 / tqparent->displayResolution_in_dpi;
167 167
     
168 168
     // All is fine? Then we rescale the bitmap in order to produce the
169 169
     // required pixmap.  Rescaling a character, however, is an art
@@ -209,10 +209,10 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
209 209
     
210 210
     // Turn the image into 8 bit
211 211
     TQByteArray translated(characterBitmaps[ch]->w * characterBitmaps[ch]->h);
212
-    Q_UINT8 *data = (Q_UINT8 *)translated.data();
212
+    TQ_UINT8 *data = (TQ_UINT8 *)translated.data();
213 213
     for(int x=0; x<characterBitmaps[ch]->w; x++)
214 214
       for(int y=0; y<characterBitmaps[ch]->h; y++) {
215
-	Q_UINT8 bit = *(characterBitmaps[ch]->bits + characterBitmaps[ch]->bytes_wide*y + (x >> 3));
215
+	TQ_UINT8 bit = *(characterBitmaps[ch]->bits + characterBitmaps[ch]->bytes_wide*y + (x >> 3));
216 216
 	bit = bit >> (x & 7);
217 217
 	bit = bit & 1;
218 218
 	data[characterBitmaps[ch]->w*y + x] = bit;
@@ -220,7 +220,7 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
220 220
     
221 221
     // Now shrink the image. We shrink the X-direction first
222 222
     TQByteArray xshrunk(shrunk_width*characterBitmaps[ch]->h);
223
-    Q_UINT8 *xdata = (Q_UINT8 *)xshrunk.data();
223
+    TQ_UINT8 *xdata = (TQ_UINT8 *)xshrunk.data();
224 224
     
225 225
     // Do the shrinking. The pixel (x,y) that we want to calculate
226 226
     // corresponds to the line segment from 
@@ -231,7 +231,7 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
231 231
 
232 232
     for(int y=0; y<characterBitmaps[ch]->h; y++)
233 233
       for(int x=0; x<shrunk_width; x++) {
234
-	Q_UINT32 value = 0;
234
+	TQ_UINT32 value = 0;
235 235
 	double destStartX = shrinkFactor*x+srcXTrans;
236 236
 	double destEndX   = shrinkFactor*(x+1)+srcXTrans;
237 237
 	for(int srcX=(int)ceil(destStartX); srcX<floor(destEndX); srcX++)
@@ -239,19 +239,19 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
239 239
 	    value += data[characterBitmaps[ch]->w*y + srcX] * 255;
240 240
 	
241 241
 	if (destStartX >= 0.0)
242
-	  value += (Q_UINT32) (255.0*(ceil(destStartX)-destStartX) * data[characterBitmaps[ch]->w*y + (int)floor(destStartX)]);
242
+	  value += (TQ_UINT32) (255.0*(ceil(destStartX)-destStartX) * data[characterBitmaps[ch]->w*y + (int)floor(destStartX)]);
243 243
 	if (floor(destEndX) < characterBitmaps[ch]->w)
244
-	  value += (Q_UINT32) (255.0*(destEndX-floor(destEndX)) * data[characterBitmaps[ch]->w*y + (int)floor(destEndX)]);
244
+	  value += (TQ_UINT32) (255.0*(destEndX-floor(destEndX)) * data[characterBitmaps[ch]->w*y + (int)floor(destEndX)]);
245 245
 	
246 246
 	xdata[shrunk_width*y + x] = (int)(value/shrinkFactor + 0.5);
247 247
       }
248 248
     
249 249
     // Now shrink the Y-direction
250 250
     TQByteArray xyshrunk(shrunk_width*shrunk_height);
251
-    Q_UINT8 *xydata = (Q_UINT8 *)xyshrunk.data();
251
+    TQ_UINT8 *xydata = (TQ_UINT8 *)xyshrunk.data();
252 252
     for(int x=0; x<shrunk_width; x++)
253 253
       for(int y=0; y<shrunk_height; y++) {
254
-	Q_UINT32 value = 0;
254
+	TQ_UINT32 value = 0;
255 255
 	double destStartY = shrinkFactor*y+srcYTrans;
256 256
 	double destEndY   = shrinkFactor*(y+1)+srcYTrans;
257 257
 	for(int srcY=(int)ceil(destStartY); srcY<floor(destEndY); srcY++)
@@ -259,31 +259,31 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
259 259
 	    value += xdata[shrunk_width*srcY + x];
260 260
 	
261 261
 	if (destStartY >= 0.0)
262
-	  value += (Q_UINT32) ((ceil(destStartY)-destStartY) * xdata[shrunk_width*(int)floor(destStartY) + x]);
262
+	  value += (TQ_UINT32) ((ceil(destStartY)-destStartY) * xdata[shrunk_width*(int)floor(destStartY) + x]);
263 263
 	if (floor(destEndY) < characterBitmaps[ch]->h)
264
-	  value += (Q_UINT32) ((destEndY-floor(destEndY)) * xdata[shrunk_width*(int)floor(destEndY) + x]);
264
+	  value += (TQ_UINT32) ((destEndY-floor(destEndY)) * xdata[shrunk_width*(int)floor(destEndY) + x]);
265 265
 	
266 266
 	xydata[shrunk_width*y + x] = (int)(value/shrinkFactor);
267 267
       }
268 268
     
269 269
     TQImage im32(shrunk_width, shrunk_height, 32);
270 270
     im32.setAlphaBuffer(true);
271
-    // Do QPixmaps fully support the alpha channel? If yes, we use
271
+    // Do TQPixmaps fully support the alpha channel? If yes, we use
272 272
     // that. Otherwise, use other routines as a fallback
273
-    if (parent->font_pool->QPixmapSupportsAlpha) {
273
+    if (tqparent->font_pool->TQPixmapSupportsAlpha) {
274 274
       // If the alpha channel is properly supported, we set the
275 275
       // character glyph to a colored rectangle, and define the
276 276
       // character outline only using the alpha channel. That ensures
277 277
       // good quality rendering for overlapping characters.
278
-      im32.fill(qRgb(color.red(), color.green(), color.blue()));
279
-      for(Q_UINT16 y=0; y<shrunk_height; y++) {
280
-	Q_UINT8 *destScanLine = (Q_UINT8 *)im32.scanLine(y);
281
-	for(Q_UINT16 col=0; col<shrunk_width; col++) 
278
+      im32.fill(tqRgb(color.red(), color.green(), color.blue()));
279
+      for(TQ_UINT16 y=0; y<shrunk_height; y++) {
280
+	TQ_UINT8 *destScanLine = (TQ_UINT8 *)im32.scanLine(y);
281
+	for(TQ_UINT16 col=0; col<shrunk_width; col++) 
282 282
 	  destScanLine[4*col+3] = xydata[shrunk_width*y + col];
283 283
       }
284 284
     } else {
285 285
       // If the alpha channel is not supported... QT seems to turn the
286
-      // alpha channel into a crude bitmap which is used to mask the
286
+      // alpha channel into a crude bitmap which is used to tqmask the
287 287
       // resulting TQPixmap. In this case, we define the character
288 288
       // outline using the image data, and use the alpha channel only
289 289
       // to store "maximally opaque" or "completely transparent"
@@ -291,18 +291,18 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
291 291
       // are no longer correctly drawn, but quality is still
292 292
       // sufficient for most purposes. One notable exception is output
293 293
       // from the gftodvi program, which will be partially unreadable.
294
-      Q_UINT16 rInv = 0xFF - color.red();
295
-      Q_UINT16 gInv = 0xFF - color.green();
296
-      Q_UINT16 bInv = 0xFF - color.blue();
294
+      TQ_UINT16 rInv = 0xFF - color.red();
295
+      TQ_UINT16 gInv = 0xFF - color.green();
296
+      TQ_UINT16 bInv = 0xFF - color.blue();
297 297
       
298
-      Q_UINT8 *srcScanLine = xydata;
299
-      for(Q_UINT16 y=0; y<shrunk_height; y++) {
298
+      TQ_UINT8 *srcScanLine = xydata;
299
+      for(TQ_UINT16 y=0; y<shrunk_height; y++) {
300 300
 	unsigned int *destScanLine = (unsigned int *)im32.scanLine(y);
301
-	for(Q_UINT16 col=0; col<shrunk_width; col++) {
302
-	  Q_UINT16 data =  *srcScanLine;
301
+	for(TQ_UINT16 col=0; col<shrunk_width; col++) {
302
+	  TQ_UINT16 data =  *srcScanLine;
303 303
 	  // The value stored in "data" now has the following meaning:
304 304
 	  // data = 0 -> white; data = 0xff -> use "color"
305
-	  *destScanLine = qRgba(0xFF - (rInv*data + 0x7F) / 0xFF,
305
+	  *destScanLine = tqRgba(0xFF - (rInv*data + 0x7F) / 0xFF,
306 306
 				0xFF - (gInv*data + 0x7F) / 0xFF,
307 307
 				0xFF - (bInv*data + 0x7F) / 0xFF,
308 308
 				(data > 0x03) ? 0xff : 0x00);
@@ -320,8 +320,8 @@ glyph* TeXFont_PK::getGlyph(Q_UINT16 ch, bool generateCharacterPixmap, const TQC
320 320
 
321 321
 
322 322
 
323
-#define	ADD(a, b)	((Q_UINT32 *) (((char *) a) + b))
324
-#define	SUB(a, b)	((Q_UINT32 *) (((char *) a) - b))
323
+#define	ADD(a, b)	((TQ_UINT32 *) (((char *) a) + b))
324
+#define	SUB(a, b)	((TQ_UINT32 *) (((char *) a) - b))
325 325
 
326 326
 
327 327
 
@@ -347,7 +347,7 @@ static const uchar bitflip[256] = {
347 347
   15, 143, 79, 207, 47, 175, 111, 239, 31, 159, 95, 223, 63, 191, 127, 255
348 348
 };                                                                              
349 349
 
350
-static Q_UINT32	bit_masks[33] = {
350
+static TQ_UINT32	bit_tqmasks[33] = {
351 351
 	0x0,		0x1,		0x3,		0x7,
352 352
 	0xf,		0x1f,		0x3f,		0x7f,
353 353
 	0xff,		0x1ff,		0x3ff,		0x7ff,
@@ -454,7 +454,7 @@ void TeXFont_PK::PK_skip_specials()
454 454
       case PK_NOOP :
455 455
 	break;
456 456
       default :
457
-	oops(i18n("Unexpected %1 in PK file %2").arg(PK_flag_byte).arg(parent->filename) );
457
+	oops(i18n("Unexpected %1 in PK file %2").tqarg(PK_flag_byte).tqarg(tqparent->filename) );
458 458
 	break;
459 459
       }
460 460
     }
@@ -477,11 +477,11 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
477 477
   int	n;
478 478
   int	row_bit_pos;
479 479
   bool	paint_switch;
480
-  Q_UINT32	*cp;
480
+  TQ_UINT32	*cp;
481 481
   register struct glyph *g;
482 482
   register FILE *fp = file;
483 483
   long	fpwidth;
484
-  Q_UINT32	word = 0;
484
+  TQ_UINT32	word = 0;
485 485
   int	word_weight, bytes_wide;
486 486
   int	rows_left, h_bit, count;
487 487
   
@@ -521,7 +521,7 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
521 521
     w = num(fp, n);
522 522
     h = num(fp, n);
523 523
     if (w > 0x7fff || h > 0x7fff)
524
-      oops(i18n("The character %1 is too large in file %2").arg(ch).arg(parent->filename));
524
+      oops(i18n("The character %1 is too large in file %2").tqarg(ch).tqarg(tqparent->filename));
525 525
     characterBitmaps[ch]->w = w;
526 526
     characterBitmaps[ch]->h = h;
527 527
   }
@@ -537,7 +537,7 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
537 537
     characterBitmaps[ch]->bits = new char[size != 0 ? size : 1];
538 538
   }
539 539
   
540
-  cp = (Q_UINT32 *) characterBitmaps[ch]->bits;
540
+  cp = (TQ_UINT32 *) characterBitmaps[ch]->bits;
541 541
   
542 542
   /*
543 543
    * read character data into *cp
@@ -595,12 +595,12 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
595 595
 	    h_bit -= count;
596 596
 	    word_weight -= count;
597 597
 	    if (paint_switch)
598
-	      word |= bit_masks[count] << word_weight;
598
+	      word |= bit_tqmasks[count] << word_weight;
599 599
 	    count = 0;
600 600
 	  } else 
601 601
 	    if (count >= h_bit && h_bit <= word_weight) {
602 602
 	      if (paint_switch)
603
-		word |= bit_masks[h_bit] << (word_weight - h_bit);
603
+		word |= bit_tqmasks[h_bit] << (word_weight - h_bit);
604 604
 	      *cp++ = word;
605 605
 	      /* "output" row(s) */
606 606
 	      for (i = PK_repeat_count * bytes_wide / 4; i > 0; --i) {
@@ -615,7 +615,7 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
615 615
 	      h_bit = characterBitmaps[ch]->w;
616 616
 	    } else {
617 617
 	      if (paint_switch)
618
-		word |= bit_masks[word_weight];
618
+		word |= bit_tqmasks[word_weight];
619 619
 	      *cp++ = word;
620 620
 	      word = 0;
621 621
 	      count -= word_weight;
@@ -625,10 +625,10 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
625 625
 	}
626 626
 	paint_switch = 1 - paint_switch;
627 627
       }
628
-      if (cp != ((Q_UINT32 *) (characterBitmaps[ch]->bits + bytes_wide * characterBitmaps[ch]->h)))
629
-	oops(i18n("Wrong number of bits stored:  char. %1, font %2").arg(ch).arg(parent->filename));
628
+      if (cp != ((TQ_UINT32 *) (characterBitmaps[ch]->bits + bytes_wide * characterBitmaps[ch]->h)))
629
+	oops(i18n("Wrong number of bits stored:  char. %1, font %2").tqarg(ch).tqarg(tqparent->filename));
630 630
       if (rows_left != 0 || h_bit != characterBitmaps[ch]->w)
631
-	oops(i18n("Bad pk file (%1), too many bits").arg(parent->filename));
631
+	oops(i18n("Bad pk file (%1), too many bits").tqarg(tqparent->filename));
632 632
     }
633 633
     
634 634
     // The data in the bitmap is now in the processor's bit order,
@@ -679,14 +679,14 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
679 679
 	while (count > 0) {
680 680
 	  if (count < word_weight && count < h_bit) {
681 681
 	    if (paint_switch)
682
-	      word |= bit_masks[count] << (32 - word_weight);
682
+	      word |= bit_tqmasks[count] << (32 - word_weight);
683 683
 	    h_bit -= count;
684 684
 	    word_weight -= count;
685 685
 	    count = 0;
686 686
 	  } else 
687 687
 	    if (count >= h_bit && h_bit <= word_weight) {
688 688
 	      if (paint_switch)
689
-		word |= bit_masks[h_bit] << (32 - word_weight);
689
+		word |= bit_tqmasks[h_bit] << (32 - word_weight);
690 690
 	      *cp++ = word;
691 691
 	      /* "output" row(s) */
692 692
 	      for (i = PK_repeat_count * bytes_wide / 4; i > 0; --i) {
@@ -701,7 +701,7 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
701 701
 	      h_bit = characterBitmaps[ch]->w;
702 702
 	    } else {
703 703
 	      if (paint_switch)
704
-		word |= bit_masks[word_weight] << (32 - word_weight);
704
+		word |= bit_tqmasks[word_weight] << (32 - word_weight);
705 705
 	      *cp++ = word;
706 706
 	      word = 0;
707 707
 	      count -= word_weight;
@@ -711,10 +711,10 @@ void TeXFont_PK::read_PK_char(unsigned int ch)
711 711
 	}
712 712
 	paint_switch = 1 - paint_switch;
713 713
       }
714
-      if (cp != ((Q_UINT32 *) (characterBitmaps[ch]->bits + bytes_wide * characterBitmaps[ch]->h)))
715
-	oops(i18n("Wrong number of bits stored:  char. %1, font %2").arg(ch).arg(parent->filename));
714
+      if (cp != ((TQ_UINT32 *) (characterBitmaps[ch]->bits + bytes_wide * characterBitmaps[ch]->h)))
715
+	oops(i18n("Wrong number of bits stored:  char. %1, font %2").tqarg(ch).tqarg(tqparent->filename));
716 716
       if (rows_left != 0 || h_bit != characterBitmaps[ch]->w)
717
-	oops(i18n("Bad pk file (%1), too many bits").arg(parent->filename));
717
+	oops(i18n("Bad pk file (%1), too many bits").tqarg(tqparent->filename));
718 718
     }
719 719
   } // endif: big or small Endian?
720 720
 }

+ 2
- 2
kdvi/TeXFont_PK.h View File

@@ -9,10 +9,10 @@ class glyph;
9 9
 
10 10
 class TeXFont_PK : public TeXFont {
11 11
  public:
12
-  TeXFont_PK(TeXFontDefinition *parent);
12
+  TeXFont_PK(TeXFontDefinition *tqparent);
13 13
   ~TeXFont_PK();
14 14
   
15
-  glyph* getGlyph(Q_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=Qt::black);
15
+  glyph* getGlyph(TQ_UINT16 character, bool generateCharacterPixmap=false, const TQColor& color=TQt::black);
16 16
 
17 17
  private:
18 18
   FILE         *file;		// open font file or NULL

+ 12
- 12
kdvi/TeXFont_TFM.cpp View File

@@ -21,14 +21,14 @@
21 21
 //#define DEBUG_TFM
22 22
 
23 23
 
24
-TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *parent) 
25
-  : TeXFont(parent)
24
+TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *tqparent) 
25
+  : TeXFont(tqparent)
26 26
 {
27 27
 #ifdef DEBUG_TFM
28
-  kdDebug(4300) << "TeXFont_TFM::TeXFont_TFM( parent=" << parent << " )" << endl;
28
+  kdDebug(4300) << "TeXFont_TFM::TeXFont_TFM( tqparent=" << tqparent << " )" << endl;
29 29
 #endif
30 30
 
31
-  TQFile file( parent->filename );
31
+  TQFile file( tqparent->filename );
32 32
   if ( !file.open( IO_ReadOnly ) ) {
33 33
     kdError(4300) << "TeXFont_TFM::TeXFont_TFM(): Could not read TFM file" << endl;
34 34
     return;
@@ -37,7 +37,7 @@ TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *parent)
37 37
 
38 38
   // Data from the very beginning of the TFM file, as specified in
39 39
   // "The DVI Driver Standard, Level 0", section D.2.1
40
-  Q_UINT16 lf, lh, bc, ec, nw, nh, nd;
40
+  TQ_UINT16 lf, lh, bc, ec, nw, nh, nd;
41 41
   stream >> lf >> lh >> bc >> ec >> nw >> nh >> nd;
42 42
 #ifdef DEBUG_TFM
43 43
   kdDebug(4300) << "lf= " << lf << endl
@@ -49,7 +49,7 @@ TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *parent)
49 49
 		<< "nd= " << nd << endl;
50 50
 #endif
51 51
   if ((bc > ec) || (ec >= TeXFontDefinition::max_num_of_chars_in_font)) {
52
-    kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << parent->filename << " ): The font has an invalid bc and ec entries." << endl;
52
+    kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << tqparent->filename << " ): The font has an invalid bc and ec entries." << endl;
53 53
     file.close();
54 54
     return;
55 55
   }
@@ -94,10 +94,10 @@ TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *parent)
94 94
   for(unsigned int characterCode=bc; characterCode<ec; characterCode++) {
95 95
     glyph *g = glyphtable+characterCode;
96 96
     
97
-    Q_UINT8 byte;
97
+    TQ_UINT8 byte;
98 98
     stream >> byte;
99 99
     if (byte >= nw) 
100
-      kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << parent->filename << " ): The font has an invalid Char-Info table." << endl;
100
+      kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << tqparent->filename << " ): The font has an invalid Char-Info table." << endl;
101 101
     else {
102 102
       characterWidth_in_units_of_design_size[characterCode] = widthTable_in_units_of_design_size[byte];
103 103
       g->dvi_advance_in_units_of_design_size_by_2e20 = widthTable_in_units_of_design_size[byte].value;
@@ -106,7 +106,7 @@ TeXFont_TFM::TeXFont_TFM(TeXFontDefinition *parent)
106 106
     stream >> byte;
107 107
     byte = byte >> 4;
108 108
     if (byte >= nh)
109
-      kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << parent->filename << " ): The font has an invalid Char-Info table." << endl;
109
+      kdError(4300) << "TeXFont_TFM::TeXFont_TFM( filename=" << tqparent->filename << " ): The font has an invalid Char-Info table." << endl;
110 110
     else 
111 111
       characterHeight_in_units_of_design_size[characterCode] = heightTable_in_units_of_design_size[byte];
112 112
     
@@ -122,7 +122,7 @@ TeXFont_TFM::~TeXFont_TFM()
122 122
 }
123 123
 
124 124
 
125
-glyph *TeXFont_TFM::getGlyph(Q_UINT16 characterCode, bool generateCharacterPixmap, const TQColor& color)
125
+glyph *TeXFont_TFM::getGlyph(TQ_UINT16 characterCode, bool generateCharacterPix