|
|
@ -91,14 +91,14 @@ void SQ_GLWidget::createActions()
|
|
|
|
|
|
|
|
|
|
|
|
pAFull = new KToggleAction(TQString(), 0, 0, 0, ac, "SQ GL Full");
|
|
|
|
pAFull = new KToggleAction(TQString(), 0, 0, 0, ac, "SQ GL Full");
|
|
|
|
|
|
|
|
|
|
|
|
TQString squirrel_zoom_actions = TQString::tqfromLatin1("squirrel_zoom_actions");
|
|
|
|
TQString squirrel_zoom_actions = TQString::fromLatin1("squirrel_zoom_actions");
|
|
|
|
pAZoomW->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomW->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomH->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomH->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomWH->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomWH->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoom100->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoom100->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomLast->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
pAZoomLast->setExclusiveGroup(squirrel_zoom_actions);
|
|
|
|
|
|
|
|
|
|
|
|
TQString squirrel_selection_type = TQString::tqfromLatin1("squirrel_selection_type");
|
|
|
|
TQString squirrel_selection_type = TQString::fromLatin1("squirrel_selection_type");
|
|
|
|
pASelectionEllipse->setExclusiveGroup(squirrel_selection_type);
|
|
|
|
pASelectionEllipse->setExclusiveGroup(squirrel_selection_type);
|
|
|
|
pASelectionRect->setExclusiveGroup(squirrel_selection_type);
|
|
|
|
pASelectionRect->setExclusiveGroup(squirrel_selection_type);
|
|
|
|
|
|
|
|
|
|
|
@ -236,17 +236,17 @@ void SQ_GLWidget::slotProperties()
|
|
|
|
// save tab->current image parameters and some additioanl information
|
|
|
|
// save tab->current image parameters and some additioanl information
|
|
|
|
// in list
|
|
|
|
// in list
|
|
|
|
list << tab->quickImageInfo
|
|
|
|
list << tab->quickImageInfo
|
|
|
|
<< TQString::tqfromLatin1("%1x%2").tqarg(tab->finfo.image[tab->current].w).tqarg(tab->finfo.image[tab->current].h)
|
|
|
|
<< TQString::fromLatin1("%1x%2").tqarg(tab->finfo.image[tab->current].w).tqarg(tab->finfo.image[tab->current].h)
|
|
|
|
<< TQString::tqfromLatin1("%1").tqarg(tab->finfo.image[tab->current].bpp)
|
|
|
|
<< TQString::fromLatin1("%1").tqarg(tab->finfo.image[tab->current].bpp)
|
|
|
|
<< tab->finfo.image[tab->current].colorspace
|
|
|
|
<< tab->finfo.image[tab->current].colorspace
|
|
|
|
<< tab->finfo.image[tab->current].compression
|
|
|
|
<< tab->finfo.image[tab->current].compression
|
|
|
|
<< sz
|
|
|
|
<< sz
|
|
|
|
<< TQString::tqfromLatin1("%1").tqarg((double)real_size / tab->fmt_size, 0, 'f', 2)
|
|
|
|
<< TQString::fromLatin1("%1").tqarg((double)real_size / tab->fmt_size, 0, 'f', 2)
|
|
|
|
<< ((tab->finfo.image[tab->current].interlaced) ? i18n("yes") : i18n("no"))
|
|
|
|
<< ((tab->finfo.image[tab->current].interlaced) ? i18n("yes") : i18n("no"))
|
|
|
|
<< TQString::tqfromLatin1("%1").tqarg(errors)
|
|
|
|
<< TQString::fromLatin1("%1").tqarg(errors)
|
|
|
|
<< TQString::tqfromLatin1("%1").tqarg(tab->finfo.image.size())
|
|
|
|
<< TQString::fromLatin1("%1").tqarg(tab->finfo.image.size())
|
|
|
|
<< TQString::tqfromLatin1("#%1").tqarg(tab->current+1)
|
|
|
|
<< TQString::fromLatin1("#%1").tqarg(tab->current+1)
|
|
|
|
<< TQString::tqfromLatin1("%1").tqarg(tab->finfo.image[tab->current].delay);
|
|
|
|
<< TQString::fromLatin1("%1").tqarg(tab->finfo.image[tab->current].delay);
|
|
|
|
|
|
|
|
|
|
|
|
// create dialog and setup it
|
|
|
|
// create dialog and setup it
|
|
|
|
SQ_ImageProperties prop(this);
|
|
|
|
SQ_ImageProperties prop(this);
|
|
|
@ -867,7 +867,7 @@ void SQ_GLWidget::initAccelsAndMenu()
|
|
|
|
menu->insertItem(i18n("Image"), menuImage);
|
|
|
|
menu->insertItem(i18n("Image"), menuImage);
|
|
|
|
|
|
|
|
|
|
|
|
#define SQ_ADD_KACTION(b) \
|
|
|
|
#define SQ_ADD_KACTION(b) \
|
|
|
|
(new KAction(TQString(), b, TQT_TQOBJECT(this), TQT_SLOT(slotAccelActivated()), ac, TQString::tqfromLatin1("action_%1").tqarg(b)))
|
|
|
|
(new KAction(TQString(), b, TQT_TQOBJECT(this), TQT_SLOT(slotAccelActivated()), ac, TQString::fromLatin1("action_%1").tqarg(b)))
|
|
|
|
|
|
|
|
|
|
|
|
id_saveas = menuFile->insertItem(SQ_IconLoader::instance()->loadIcon("filesaveas", KIcon::Desktop, KIcon::SizeSmall), i18n("Save As...") + "\tS", SQ_ADD_KACTION(TQt::Key_S), TQT_SLOT(activate()));
|
|
|
|
id_saveas = menuFile->insertItem(SQ_IconLoader::instance()->loadIcon("filesaveas", KIcon::Desktop, KIcon::SizeSmall), i18n("Save As...") + "\tS", SQ_ADD_KACTION(TQt::Key_S), TQT_SLOT(activate()));
|
|
|
|
|
|
|
|
|
|
|
@ -900,13 +900,13 @@ void SQ_GLWidget::initAccelsAndMenu()
|
|
|
|
menuZoom->insertItem(i18n("Zoom 2x") + "\tCtrl++", SQ_ADD_KACTION(TQt::Key_Plus+CTRL), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(i18n("Zoom 2x") + "\tCtrl++", SQ_ADD_KACTION(TQt::Key_Plus+CTRL), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(i18n("Zoom 1/2x") + "\tCtrl+-", SQ_ADD_KACTION(TQt::Key_Minus+CTRL), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(i18n("Zoom 1/2x") + "\tCtrl+-", SQ_ADD_KACTION(TQt::Key_Minus+CTRL), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertSeparator();
|
|
|
|
menuZoom->insertSeparator();
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom10016.png")), TQString::tqfromLatin1("100%") + "\t1", SQ_ADD_KACTION(TQt::Key_1), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom10016.png")), TQString::fromLatin1("100%") + "\t1", SQ_ADD_KACTION(TQt::Key_1), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom20016.png")), TQString::tqfromLatin1("200%") + "\t2", SQ_ADD_KACTION(TQt::Key_2), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom20016.png")), TQString::fromLatin1("200%") + "\t2", SQ_ADD_KACTION(TQt::Key_2), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom30016.png")), TQString::tqfromLatin1("300%") + "\t3", SQ_ADD_KACTION(TQt::Key_3), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom30016.png")), TQString::fromLatin1("300%") + "\t3", SQ_ADD_KACTION(TQt::Key_3), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom50016.png")), TQString::tqfromLatin1("500%") + "\t5", SQ_ADD_KACTION(TQt::Key_5), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom50016.png")), TQString::fromLatin1("500%") + "\t5", SQ_ADD_KACTION(TQt::Key_5), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom70016.png")), TQString::tqfromLatin1("700%") + "\t7", SQ_ADD_KACTION(TQt::Key_7), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom70016.png")), TQString::fromLatin1("700%") + "\t7", SQ_ADD_KACTION(TQt::Key_7), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom90016.png")), TQString::tqfromLatin1("900%") + "\t9", SQ_ADD_KACTION(TQt::Key_9), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom90016.png")), TQString::fromLatin1("900%") + "\t9", SQ_ADD_KACTION(TQt::Key_9), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom100016.png")), TQString::tqfromLatin1("1000%") + "\t0", SQ_ADD_KACTION(TQt::Key_0), TQT_SLOT(activate()));
|
|
|
|
menuZoom->insertItem(TQPixmap(locate("data", "images/menu/zoom100016.png")), TQString::fromLatin1("1000%") + "\t0", SQ_ADD_KACTION(TQt::Key_0), TQT_SLOT(activate()));
|
|
|
|
|
|
|
|
|
|
|
|
menuMove->insertItem(TQPixmap(locate("data", "images/menu/moveLeft16.png")), i18n("Move left") + "\tRight", SQ_ADD_KACTION(TQt::Key_Right), TQT_SLOT(activate()));
|
|
|
|
menuMove->insertItem(TQPixmap(locate("data", "images/menu/moveLeft16.png")), i18n("Move left") + "\tRight", SQ_ADD_KACTION(TQt::Key_Right), TQT_SLOT(activate()));
|
|
|
|
menuMove->insertItem(TQPixmap(locate("data", "images/menu/moveRight16.png")), i18n("Move right") + "\tLeft", SQ_ADD_KACTION(TQt::Key_Left), TQT_SLOT(activate()));
|
|
|
|
menuMove->insertItem(TQPixmap(locate("data", "images/menu/moveRight16.png")), i18n("Move right") + "\tLeft", SQ_ADD_KACTION(TQt::Key_Left), TQT_SLOT(activate()));
|
|
|
@ -1312,7 +1312,7 @@ void SQ_GLWidget::slotChangeTab(int id)
|
|
|
|
|
|
|
|
|
|
|
|
for(;it != itEnd;++it, ++i)
|
|
|
|
for(;it != itEnd;++it, ++i)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
mid = images->insertItem(TQString::tqfromLatin1("#%1 [%2x%3@%4]").tqarg(i+1).tqarg((*it).w).tqarg((*it).h).tqarg((*it).bpp));
|
|
|
|
mid = images->insertItem(TQString::fromLatin1("#%1 [%2x%3@%4]").tqarg(i+1).tqarg((*it).w).tqarg((*it).h).tqarg((*it).bpp));
|
|
|
|
images->setItemParameter(mid, i);
|
|
|
|
images->setItemParameter(mid, i);
|
|
|
|
|
|
|
|
|
|
|
|
if(i == tab->current)
|
|
|
|
if(i == tab->current)
|
|
|
@ -1493,7 +1493,7 @@ void SQ_GLWidget::setClearColor()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// system color
|
|
|
|
// system color
|
|
|
|
case 0:
|
|
|
|
case 0:
|
|
|
|
color = tqcolorGroup().color(TQColorGroup::Base);
|
|
|
|
color = colorGroup().color(TQColorGroup::Base);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
// custom color
|
|
|
|
// custom color
|
|
|
@ -1623,7 +1623,7 @@ void SQ_GLWidget::createMarks()
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
void SQ_GLWidget::updateCurrentFileInfo()
|
|
|
|
void SQ_GLWidget::updateCurrentFileInfo()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
TQString status = TQString::tqfromLatin1("%1x%2@%3")
|
|
|
|
TQString status = TQString::fromLatin1("%1x%2@%3")
|
|
|
|
.tqarg(tab->finfo.image[tab->current].w)
|
|
|
|
.tqarg(tab->finfo.image[tab->current].w)
|
|
|
|
.tqarg(tab->finfo.image[tab->current].h)
|
|
|
|
.tqarg(tab->finfo.image[tab->current].h)
|
|
|
|
.tqarg(tab->finfo.image[tab->current].bpp);
|
|
|
|
.tqarg(tab->finfo.image[tab->current].bpp);
|
|
|
@ -1667,7 +1667,7 @@ void SQ_GLWidget::calcFrameLabelWidth()
|
|
|
|
#ifndef KSQUIRREL_PART
|
|
|
|
#ifndef KSQUIRREL_PART
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->setFixedWidth(
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->setFixedWidth(
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->fontMetrics()
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->fontMetrics()
|
|
|
|
.boundingRect(TQString::tqfromLatin1("0%1/0%2").tqarg(tab->total).tqarg(tab->total)).width());
|
|
|
|
.boundingRect(TQString::fromLatin1("0%1/0%2").tqarg(tab->total).tqarg(tab->total)).width());
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -1680,9 +1680,9 @@ void SQ_GLWidget::calcFrameLabelWidth()
|
|
|
|
void SQ_GLWidget::frameChanged()
|
|
|
|
void SQ_GLWidget::frameChanged()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifndef KSQUIRREL_PART
|
|
|
|
#ifndef KSQUIRREL_PART
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->setText(TQString::tqfromLatin1("%1/%2").tqarg(tab->current+1).tqarg(tab->total));
|
|
|
|
SQ_GLView::window()->sbarWidget("SBFrame")->setText(TQString::fromLatin1("%1/%2").tqarg(tab->current+1).tqarg(tab->total));
|
|
|
|
#else
|
|
|
|
#else
|
|
|
|
t_glv.sbarWidget("SBFrame")->setText(TQString::tqfromLatin1("%1/%2").tqarg(tab->current+1).tqarg(tab->total));
|
|
|
|
t_glv.sbarWidget("SBFrame")->setText(TQString::fromLatin1("%1/%2").tqarg(tab->current+1).tqarg(tab->total));
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|