summaryrefslogtreecommitdiff
authorzecke <zecke>2004-02-25 20:55:24 (UTC)
committer zecke <zecke>2004-02-25 20:55:24 (UTC)
commitad8cbdb693ecccd2a67a8294014360b70ad4253a (patch) (unidiff)
treec0d3bdc8d3b3d143d195170fee2cc54045840fa6
parentddab47e21543e806a7de978985f77ea2b9e8c214 (diff)
downloadopie-ad8cbdb693ecccd2a67a8294014360b70ad4253a.zip
opie-ad8cbdb693ecccd2a67a8294014360b70ad4253a.tar.gz
opie-ad8cbdb693ecccd2a67a8294014360b70ad4253a.tar.bz2
remove the stupid #ifdef __i386__
We're on Opie and don't need to mess with Qtopia.. we fix up broken Qt usage of legacy via a __weak__ symbol hack
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/apps/embeddedkonsole/konsole.cpp2
1 files changed, 0 insertions, 2 deletions
diff --git a/core/apps/embeddedkonsole/konsole.cpp b/core/apps/embeddedkonsole/konsole.cpp
index 1c613a9..2c0001f 100644
--- a/core/apps/embeddedkonsole/konsole.cpp
+++ b/core/apps/embeddedkonsole/konsole.cpp
@@ -409,52 +409,50 @@ void Konsole::init(const char* _pgm, QStrList & _args)
409 409
410 if (sizes.count() > 0) 410 if (sizes.count() > 0)
411 { 411 {
412 QPopupMenu *sizeMenu; 412 QPopupMenu *sizeMenu;
413 QFont f; 413 QFont f;
414 int last_width = -1; 414 int last_width = -1;
415 sizeMenu = NULL; 415 sizeMenu = NULL;
416 416
417 for(uint i = 0; i < (uint)sizes.count() + 4; i++) 417 for(uint i = 0; i < (uint)sizes.count() + 4; i++)
418 { 418 {
419 // printf("family %s size %d ", familyNames[j].latin1(), sizes[i]); 419 // printf("family %s size %d ", familyNames[j].latin1(), sizes[i]);
420 // need to divide by 10 on the Z, but not otherwise 420 // need to divide by 10 on the Z, but not otherwise
421 int size; 421 int size;
422 422
423 if (i >= (uint)sizes.count()) 423 if (i >= (uint)sizes.count())
424 { 424 {
425 // try for expandable fonts 425 // try for expandable fonts
426 size = sizes[sizes.count()-1] + 2 * (i - sizes.count() + 1); 426 size = sizes[sizes.count()-1] + 2 * (i - sizes.count() + 1);
427 } 427 }
428 else 428 else
429 { 429 {
430 printf("sizes[%d] = %d\n", i, sizes[i]); 430 printf("sizes[%d] = %d\n", i, sizes[i]);
431 size = sizes[i]; 431 size = sizes[i];
432 } 432 }
433#ifndef __i386__
434 // a hack, sizes on Z seem to be points*10 433 // a hack, sizes on Z seem to be points*10
435 size /= 10; 434 size /= 10;
436#endif
437 435
438 f = QFont(familyNames[j], size); 436 f = QFont(familyNames[j], size);
439 f.setFixedPitch(true); 437 f.setFixedPitch(true);
440 QFontMetrics fm(f); 438 QFontMetrics fm(f);
441 // don't trust f.fixedPitch() or f.exactMatch(), they lie!! 439 // don't trust f.fixedPitch() or f.exactMatch(), they lie!!
442 if (fm.width("l") == fm.width("m") 440 if (fm.width("l") == fm.width("m")
443 && (i < (uint)sizes.count() 441 && (i < (uint)sizes.count()
444 || fm.width("m") > last_width)) 442 || fm.width("m") > last_width))
445 { 443 {
446 if (i < (uint)sizes.count()) 444 if (i < (uint)sizes.count())
447 { 445 {
448 last_width = fm.width("m"); 446 last_width = fm.width("m");
449 } 447 }
450 if (sizeMenu == NULL) 448 if (sizeMenu == NULL)
451 { 449 {
452 sizeMenu = new QPopupMenu(); 450 sizeMenu = new QPopupMenu();
453 } 451 }
454 int id = sizeMenu->insertItem(QString("%1").arg(size), fontIndex); 452 int id = sizeMenu->insertItem(QString("%1").arg(size), fontIndex);
455 sizeMenu->setItemParameter(id, fontIndex); 453 sizeMenu->setItemParameter(id, fontIndex);
456 sizeMenu->connectItem(id, this, SLOT(setFont(int))); 454 sizeMenu->connectItem(id, this, SLOT(setFont(int)));
457 QString name = s + " " + QString::number(size); 455 QString name = s + " " + QString::number(size);
458 fonts.append(new VTFont(name, f, familyNames[j], familyNum, size)); 456 fonts.append(new VTFont(name, f, familyNames[j], familyNum, size));
459 if (familyNames[j] == cfgFontName && size == cfgFontSize) 457 if (familyNames[j] == cfgFontName && size == cfgFontSize)
460 { 458 {