mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-27 03:36:39 +00:00
gtk_patch_2003_10_28
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7997 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
29cc4f048b
commit
6d49cbadf0
@ -1,3 +1,12 @@
|
||||
2003-10-28 Huang Ying <hying_caritas@163.com>
|
||||
* codeConvert.h (etc): Change FcChar to XftChar according to the libxft
|
||||
interface changing.
|
||||
* FileDialogPrivate.C : get rid of button support in FileDialog
|
||||
because of the implementation of Gtk::FileSelection changed.
|
||||
* glade/.cvsignore : add *.gladep, which is generated during editing
|
||||
*.galde
|
||||
* Add MathPanel, TableCreate and Url dialog
|
||||
|
||||
2003-10-15 José Matos <jamatos@lyx.org>
|
||||
|
||||
* lyx_gui.C (start): add lyxsocket.
|
||||
|
@ -57,7 +57,7 @@
|
||||
#include "FormGraphics.h"
|
||||
#include "FormInclude.h"
|
||||
#include "FormLog.h"
|
||||
#include "FormMathsPanel.h"
|
||||
#include "GMathPanel.h"
|
||||
#include "FormMathsBitmap.h"
|
||||
#include "FormMathsDelim.h"
|
||||
#include "FormMathsMatrix.h"
|
||||
@ -70,9 +70,9 @@
|
||||
#include "FormTabular.h"
|
||||
#include "FormTexinfo.h"
|
||||
#include "FormShowFile.h"
|
||||
#include "FormTabularCreate.h"
|
||||
#include "GTableCreate.h"
|
||||
#include "FormToc.h"
|
||||
#include "FormUrl.h"
|
||||
#include "GUrl.h"
|
||||
#include "FormVCLog.h"
|
||||
#include "FormWrap.h"
|
||||
|
||||
@ -230,8 +230,9 @@ Dialog * Dialogs::build(string const & name)
|
||||
dialog->bc().bp(new OkCancelPolicy);
|
||||
|
||||
} else if (name == "mathpanel") {
|
||||
dialog->bc().view(new GBC(dialog->bc()));
|
||||
dialog->setController(new ControlMath(*dialog));
|
||||
dialog->setView(new FormMathsPanel(*dialog));
|
||||
dialog->setView(new GMathPanel(*dialog));
|
||||
dialog->bc().bp(new IgnorantPolicy);
|
||||
|
||||
} else if (name == "mathaccents") {
|
||||
@ -435,8 +436,9 @@ Dialog * Dialogs::build(string const & name)
|
||||
dialog->setView(new FormTabular(*dialog));
|
||||
dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy);
|
||||
} else if (name == "tabularcreate") {
|
||||
dialog->bc().view(new GBC(dialog->bc()));
|
||||
dialog->setController(new ControlTabularCreate(*dialog));
|
||||
dialog->setView(new FormTabularCreate(*dialog));
|
||||
dialog->setView(new GTableCreate(*dialog));
|
||||
dialog->bc().bp(new IgnorantPolicy);
|
||||
} else if (name == "texinfo") {
|
||||
dialog->setController(new ControlTexinfo(*dialog));
|
||||
@ -453,8 +455,9 @@ Dialog * Dialogs::build(string const & name)
|
||||
dialog->setView(new FormToc(*dialog));
|
||||
dialog->bc().bp(new OkCancelPolicy);
|
||||
} else if (name == "url") {
|
||||
dialog->bc().view(new GBC(dialog->bc()));
|
||||
dialog->setController(new ControlCommand(*dialog, name));
|
||||
dialog->setView(new FormUrl(*dialog));
|
||||
dialog->setView(new GUrl(*dialog));
|
||||
dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy);
|
||||
} else if (name == "vclog") {
|
||||
dialog->setController(new ControlVCLog(*dialog));
|
||||
|
@ -23,7 +23,7 @@ FileDialog::Private::Private(string const & title,
|
||||
action_(action)
|
||||
{
|
||||
fileSelection_.set_title(title);
|
||||
fileSelection_.get_button_area()->children().push_back(
|
||||
/* fileSelection_.get_button_area()->children().push_back(
|
||||
Gtk::Box_Helpers::Element(button1_));
|
||||
fileSelection_.get_button_area()->children().push_back(
|
||||
Gtk::Box_Helpers::Element(button2_));
|
||||
@ -44,7 +44,7 @@ FileDialog::Private::Private(string const & title,
|
||||
Glib::locale_to_utf8(b2.first.substr(0, pos)));
|
||||
dir2_ = b2.second;
|
||||
button2_.show();
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
|
||||
|
328
src/frontends/gtk/GMathPanel.C
Normal file
328
src/frontends/gtk/GMathPanel.C
Normal file
@ -0,0 +1,328 @@
|
||||
/**
|
||||
* \file GMathPanel.C
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
#include <gtkmm.h>
|
||||
|
||||
#include <libglademm.h>
|
||||
|
||||
#include "ControlMath.h"
|
||||
#include "GMathPanel.h"
|
||||
#include "support/filetools.h"
|
||||
#include "support/lstrings.h"
|
||||
|
||||
#include "deco.xpm"
|
||||
#include "delim.xpm"
|
||||
#include "equation.xpm"
|
||||
#include "frac.xpm"
|
||||
#include "matrix.xpm"
|
||||
#include "space.xpm"
|
||||
#include "style.xpm"
|
||||
#include "sqrt.xpm"
|
||||
#include "sub.xpm"
|
||||
#include "super.xpm"
|
||||
|
||||
using std::string;
|
||||
|
||||
GMathPanel::GMathPanel(Dialog & parent)
|
||||
: GViewCB<ControlMath, GViewGladeB>(parent, _("Math Panel"))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::doBuild()
|
||||
{
|
||||
string const gladeName =
|
||||
lyx::support::LibFileSearch("glade", "mathPanel", "glade");
|
||||
xml_ = Gnome::Glade::Xml::create(gladeName);
|
||||
Gtk::Button * close;
|
||||
|
||||
//1
|
||||
Gtk::Button * sqrt;
|
||||
Gtk::Button * frac;
|
||||
Gtk::Button * delim;
|
||||
Gtk::Button * deco;
|
||||
Gtk::Button * space;
|
||||
|
||||
//2
|
||||
Gtk::Button * super;
|
||||
Gtk::Button * sub;
|
||||
Gtk::Button * style;
|
||||
Gtk::Button * matrix;
|
||||
Gtk::Button * equation;
|
||||
|
||||
//3
|
||||
Gtk::Button * boperator;
|
||||
Gtk::Button * brelats;
|
||||
Gtk::Button * arrow;
|
||||
|
||||
//4
|
||||
Gtk::Button * varSize;
|
||||
Gtk::Button * dots;
|
||||
Gtk::Button * misc;
|
||||
|
||||
//5
|
||||
Gtk::Button * greek;
|
||||
Gtk::Button * amsArrows;
|
||||
Gtk::Button * amsBrel;
|
||||
|
||||
//6
|
||||
Gtk::Button * amsNrel;
|
||||
Gtk::Button * amsOps;
|
||||
Gtk::Button * amsMisc;
|
||||
|
||||
xml_->get_widget("Close", close);
|
||||
close->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onCancel));
|
||||
|
||||
//1
|
||||
xml_->get_widget("Sqrt", sqrt);
|
||||
xml_->get_widget("Frac", frac);
|
||||
xml_->get_widget("Delim", delim);
|
||||
xml_->get_widget("Deco", deco);
|
||||
xml_->get_widget("Space", space);
|
||||
|
||||
//2
|
||||
xml_->get_widget("Super", super);
|
||||
xml_->get_widget("Sub", sub);
|
||||
xml_->get_widget("Style", style);
|
||||
xml_->get_widget("Matrix", matrix);
|
||||
xml_->get_widget("Equation", equation);
|
||||
|
||||
//3
|
||||
xml_->get_widget("Boperator", boperator);
|
||||
xml_->get_widget("Brelate", brelats);
|
||||
xml_->get_widget("Arrow", arrow);
|
||||
|
||||
//4
|
||||
xml_->get_widget("VarSize", varSize);
|
||||
xml_->get_widget("Dots", dots);
|
||||
xml_->get_widget("Misc", misc);
|
||||
|
||||
//5
|
||||
xml_->get_widget("Greek", greek);
|
||||
xml_->get_widget("AmsArrow", amsArrows);
|
||||
xml_->get_widget("AmsBrel", amsBrel);
|
||||
|
||||
//6
|
||||
xml_->get_widget("AmsNrel", amsNrel);
|
||||
xml_->get_widget("AmsOps", amsOps);
|
||||
xml_->get_widget("AmsMisc", amsMisc);
|
||||
|
||||
Glib::RefPtr<Gdk::Bitmap> mask;
|
||||
Glib::RefPtr<Gdk::Pixmap> pixmap;
|
||||
Glib::RefPtr<Gdk::Colormap> clrmap = window()->get_colormap();
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::sqrt_xpm);
|
||||
Gtk::Image * iSqrt = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iSqrt->show();
|
||||
sqrt->add(*iSqrt);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::frac);
|
||||
Gtk::Image * iFrac = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iFrac->show();
|
||||
frac->add(*iFrac);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::delim);
|
||||
Gtk::Image * iDelim = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iDelim->show();
|
||||
delim->add(*iDelim);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::deco);
|
||||
Gtk::Image * iDeco = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iDeco->show();
|
||||
deco->add(*iDeco);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::space_xpm);
|
||||
Gtk::Image * iSpace = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iSpace->show();
|
||||
space->add(*iSpace);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::super_xpm);
|
||||
Gtk::Image * iSuper = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iSuper->show();
|
||||
super->add(*iSuper);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::sub_xpm);
|
||||
Gtk::Image * iSub = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iSub->show();
|
||||
sub->add(*iSub);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::style_xpm);
|
||||
Gtk::Image * iStyle = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iStyle->show();
|
||||
style->add(*iStyle);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::matrix);
|
||||
Gtk::Image * iMatrix = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iMatrix->show();
|
||||
matrix->add(*iMatrix);
|
||||
|
||||
pixmap = Gdk::Pixmap::create_from_xpm(clrmap, mask, ::equation);
|
||||
Gtk::Image * iEquation = SigC::manage(new Gtk::Image(pixmap, mask));
|
||||
iEquation->show();
|
||||
equation->add(*iEquation);
|
||||
|
||||
arrow->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"matharrows"));
|
||||
deco->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathaccents"));
|
||||
boperator->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathoperators"));
|
||||
brelats->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathrelations"));
|
||||
greek->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathgreek"));
|
||||
misc->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathmisc"));
|
||||
dots->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathdots"));
|
||||
varSize->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathbigoperators"));
|
||||
amsMisc->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathamsmisc"));
|
||||
amsArrows->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathamsarrows"));
|
||||
amsBrel->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathamsrelations"));
|
||||
amsNrel->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathamsnegatedrelations"));
|
||||
amsOps->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathamsoperators"));
|
||||
delim->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathdelimiter"));
|
||||
matrix->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathmatrix"));
|
||||
space->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathspace"));
|
||||
style->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onShowDialog),
|
||||
"mathstyle"));
|
||||
|
||||
super->signal_clicked().connect(
|
||||
SigC::slot(*this, &GMathPanel::onSuperClicked));
|
||||
sub->signal_clicked().connect(
|
||||
SigC::slot(*this, &GMathPanel::onSubClicked));
|
||||
equation->signal_clicked().connect(
|
||||
SigC::slot(*this, &GMathPanel::onEquationClicked));
|
||||
|
||||
frac->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onInsert),
|
||||
"frac"));
|
||||
sqrt->signal_clicked().connect(
|
||||
SigC::bind<char const *>(
|
||||
SigC::slot(*this,
|
||||
&GMathPanel::onInsert),
|
||||
"sqrt"));
|
||||
|
||||
// Functions ListView
|
||||
xml_->get_widget("Functions", functions_);
|
||||
listCols_.add(listCol_);
|
||||
listStore_ = Gtk::ListStore::create(listCols_);
|
||||
functions_->set_model(listStore_);
|
||||
functions_->append_column("Functions", listCol_);
|
||||
listSel_ = functions_->get_selection();
|
||||
listSel_->signal_changed().connect(
|
||||
SigC::slot(*this, &GMathPanel::onFunctionSelected));
|
||||
for (int i = 0; i < nr_function_names; ++i)
|
||||
(*listStore_->append())[listCol_] =
|
||||
Glib::locale_to_utf8(function_names[i]);
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onFunctionSelected()
|
||||
{
|
||||
Gtk::TreeModel::iterator it = listSel_->get_selected();
|
||||
Glib::ustring sel = (*it)[listCol_];
|
||||
controller().dispatchInsert(
|
||||
Glib::locale_from_utf8(sel));
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onShowDialog(char const * dialogName)
|
||||
{
|
||||
controller().showDialog(dialogName);
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onSuperClicked()
|
||||
{
|
||||
controller().dispatchSuperscript();
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onSubClicked()
|
||||
{
|
||||
controller().dispatchSubscript();
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onEquationClicked()
|
||||
{
|
||||
controller().dispatchToggleDisplay();
|
||||
}
|
||||
|
||||
|
||||
void GMathPanel::onInsert(char const * what)
|
||||
{
|
||||
controller().dispatchInsert(what);
|
||||
}
|
41
src/frontends/gtk/GMathPanel.h
Normal file
41
src/frontends/gtk/GMathPanel.h
Normal file
@ -0,0 +1,41 @@
|
||||
// -*- C++ -*-
|
||||
/**
|
||||
* \file GMathPanel.h
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#ifndef GMATH_PANEL_H
|
||||
#define GMATH_PANEL_H
|
||||
|
||||
#include "GViewBase.h"
|
||||
#include "support/lstrings.h"
|
||||
|
||||
class ControlMath;
|
||||
|
||||
class GMathPanel : public GViewCB<ControlMath, GViewGladeB>
|
||||
{
|
||||
public:
|
||||
GMathPanel(Dialog & parent);
|
||||
private:
|
||||
virtual void apply() {}
|
||||
virtual void update() {}
|
||||
virtual void doBuild();
|
||||
void onShowDialog(char const * dialogName);
|
||||
void onSuperClicked();
|
||||
void onSubClicked();
|
||||
void onEquationClicked();
|
||||
void onInsert(char const * what);
|
||||
void onFunctionSelected();
|
||||
Gtk::TreeView * functions_;
|
||||
Gtk::TreeModelColumn<Glib::ustring> listCol_;
|
||||
Gtk::TreeModel::ColumnRecord listCols_;
|
||||
Glib::RefPtr<Gtk::ListStore> listStore_;
|
||||
Glib::RefPtr<Gtk::TreeSelection> listSel_;
|
||||
};
|
||||
|
||||
#endif
|
@ -232,7 +232,7 @@ Painter & GPainter::text(int x, int y, wchar_t const * s, int ls,
|
||||
XftDraw * draw = owner_.getXftDraw();
|
||||
if (f.realShape() != LyXFont::SMALLCAPS_SHAPE) {
|
||||
XftDrawString32(draw, xftClr, font, x, y,
|
||||
wcsToFcChar32StrFast(s), ls);
|
||||
wcsToXftChar32StrFast(s), ls);
|
||||
} else {
|
||||
LyXFont smallfont(f);
|
||||
smallfont.decSize().decSize().setShape(LyXFont::UP_SHAPE);
|
||||
@ -243,11 +243,11 @@ Painter & GPainter::text(int x, int y, wchar_t const * s, int ls,
|
||||
c = lyx::support::uppercase(s[i]);
|
||||
if(c != s[i]) {
|
||||
XftDrawString32(draw, xftClr, fontS, tmpx, y,
|
||||
wcsToFcChar32StrFast(&c), 1);
|
||||
wcsToXftChar32StrFast(&c), 1);
|
||||
tmpx += font_metrics::width(c, smallfont);
|
||||
} else {
|
||||
XftDrawString32(draw, xftClr, font, tmpx, y,
|
||||
wcsToFcChar32StrFast(&c), 1);
|
||||
wcsToXftChar32StrFast(&c), 1);
|
||||
tmpx += font_metrics::width(c, f);
|
||||
}
|
||||
}
|
||||
|
57
src/frontends/gtk/GTableCreate.C
Normal file
57
src/frontends/gtk/GTableCreate.C
Normal file
@ -0,0 +1,57 @@
|
||||
/**
|
||||
* \file GTableCreate.C
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
#include <gtkmm.h>
|
||||
|
||||
#include <libglademm.h>
|
||||
|
||||
#include "ControlTabularCreate.h"
|
||||
#include "GTableCreate.h"
|
||||
#include "support/filetools.h"
|
||||
#include "support/lstrings.h"
|
||||
|
||||
using std::string;
|
||||
|
||||
GTableCreate::GTableCreate(Dialog & parent)
|
||||
: GViewCB<ControlTabularCreate, GViewGladeB>(parent, _("Insert Table"))
|
||||
{
|
||||
}
|
||||
|
||||
void GTableCreate::doBuild()
|
||||
{
|
||||
string const gladeName =
|
||||
lyx::support::LibFileSearch("glade", "tableCreate", "glade");
|
||||
xml_ = Gnome::Glade::Xml::create(gladeName);
|
||||
Gtk::Button * ok;
|
||||
Gtk::Button * apply;
|
||||
Gtk::Button * cancel;
|
||||
xml_->get_widget("Ok", ok);
|
||||
xml_->get_widget("Apply", apply);
|
||||
xml_->get_widget("Cancel", cancel);
|
||||
xml_->get_widget("Rows", rows_);
|
||||
xml_->get_widget("Columns", columns_);
|
||||
bcview().setOK(ok);
|
||||
bcview().setCancel(cancel);
|
||||
bcview().setApply(apply);
|
||||
ok->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onOK));
|
||||
apply->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onApply));
|
||||
cancel->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onCancel));
|
||||
}
|
||||
|
||||
void GTableCreate::apply()
|
||||
{
|
||||
int rows = rows_->get_value_as_int();
|
||||
int columns = columns_->get_value_as_int();
|
||||
controller().params() = std::make_pair(columns, rows);
|
||||
}
|
31
src/frontends/gtk/GTableCreate.h
Normal file
31
src/frontends/gtk/GTableCreate.h
Normal file
@ -0,0 +1,31 @@
|
||||
// -*- C++ -*-
|
||||
/**
|
||||
* \file GTableCreate.h
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#ifndef GTABLE_CREATE_H
|
||||
#define GTABLE_CREATE_H
|
||||
|
||||
#include "GViewBase.h"
|
||||
|
||||
class ControlTableCreate;
|
||||
|
||||
class GTableCreate : public GViewCB<ControlTabularCreate, GViewGladeB>
|
||||
{
|
||||
public:
|
||||
GTableCreate(Dialog & parent);
|
||||
private:
|
||||
virtual void apply();
|
||||
virtual void doBuild();
|
||||
virtual void update() {};
|
||||
Gtk::SpinButton *rows_;
|
||||
Gtk::SpinButton *columns_;
|
||||
};
|
||||
|
||||
#endif
|
97
src/frontends/gtk/GUrl.C
Normal file
97
src/frontends/gtk/GUrl.C
Normal file
@ -0,0 +1,97 @@
|
||||
/**
|
||||
* \file GUrl.C
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
#include <gtkmm.h>
|
||||
|
||||
#include <libglademm.h>
|
||||
|
||||
#include "ControlCommand.h"
|
||||
#include "GUrl.h"
|
||||
#include "support/filetools.h"
|
||||
#include "support/lstrings.h"
|
||||
|
||||
using std::string;
|
||||
|
||||
GUrl::GUrl(Dialog & parent)
|
||||
: GViewCB<ControlCommand, GViewGladeB>(parent, _("URL"))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void GUrl::doBuild()
|
||||
{
|
||||
string const gladeName =
|
||||
lyx::support::LibFileSearch("glade", "url", "glade");
|
||||
xml_ = Gnome::Glade::Xml::create(gladeName);
|
||||
Gtk::Button * restore;
|
||||
Gtk::Button * ok;
|
||||
Gtk::Button * apply;
|
||||
Gtk::Button * cancel;
|
||||
xml_->get_widget("Url", url_);
|
||||
xml_->get_widget("Name", name_);
|
||||
xml_->get_widget("Html", htmlType_);
|
||||
xml_->get_widget("Restore", restore);
|
||||
xml_->get_widget("Ok", ok);
|
||||
xml_->get_widget("Apply", apply);
|
||||
xml_->get_widget("Cancel", cancel);
|
||||
bcview().setOK(ok);
|
||||
bcview().setCancel(cancel);
|
||||
bcview().setApply(apply);
|
||||
bcview().setRestore(restore);
|
||||
bcview().addReadOnly(name_);
|
||||
bcview().addReadOnly(url_);
|
||||
bcview().addReadOnly(htmlType_);
|
||||
|
||||
ok->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onOK));
|
||||
apply->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onApply));
|
||||
cancel->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onCancel));
|
||||
restore->signal_clicked().connect(
|
||||
SigC::slot(*this, &GViewBase::onRestore));
|
||||
url_->signal_changed().connect(
|
||||
SigC::slot(*this, &GUrl::onEntryChanged));
|
||||
name_->signal_changed().connect(
|
||||
SigC::slot(*this, &GUrl::onEntryChanged));
|
||||
}
|
||||
|
||||
|
||||
void GUrl::onEntryChanged()
|
||||
{
|
||||
bc().valid(!url_->get_text().empty() || !name_->get_text().empty());
|
||||
}
|
||||
|
||||
|
||||
void GUrl::update()
|
||||
{
|
||||
url_->set_text(Glib::locale_to_utf8(
|
||||
controller().params().getContents()));
|
||||
name_->set_text(Glib::locale_to_utf8(
|
||||
controller().params().getOptions()));
|
||||
if (controller().params().getCmdName() == "url")
|
||||
htmlType_->set_active(false);
|
||||
else
|
||||
htmlType_->set_active();
|
||||
}
|
||||
|
||||
|
||||
void GUrl::apply()
|
||||
{
|
||||
controller().params().setContents(
|
||||
Glib::locale_to_utf8(url_->get_text()));
|
||||
controller().params().setOptions(
|
||||
Glib::locale_to_utf8(name_->get_text()));
|
||||
if (htmlType_->get_active())
|
||||
controller().params().setCmdName("htmlurl");
|
||||
else
|
||||
controller().params().setCmdName("url");
|
||||
}
|
33
src/frontends/gtk/GUrl.h
Normal file
33
src/frontends/gtk/GUrl.h
Normal file
@ -0,0 +1,33 @@
|
||||
// -*- C++ -*-
|
||||
/**
|
||||
* \file GUrl.h
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Huang Ying
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#ifndef GURL_H
|
||||
#define GURL_H
|
||||
|
||||
#include "GViewBase.h"
|
||||
|
||||
class ControlCommand;
|
||||
|
||||
class GUrl : public GViewCB<ControlCommand, GViewGladeB>
|
||||
{
|
||||
public:
|
||||
GUrl(Dialog & parent);
|
||||
private:
|
||||
virtual void apply();
|
||||
virtual void doBuild();
|
||||
virtual void update();
|
||||
void onEntryChanged();
|
||||
Gtk::Entry * url_;
|
||||
Gtk::Entry * name_;
|
||||
Gtk::CheckButton * htmlType_;
|
||||
};
|
||||
|
||||
#endif
|
@ -82,7 +82,9 @@ XftColor * ColorHandler::getXftColor(LColor_color clr)
|
||||
Visual * visual = GDK_VISUAL_XVISUAL(
|
||||
owner_.getColormap()->get_visual()->gobj());
|
||||
XftColorAllocName(owner_.getDisplay(), visual, colormap,
|
||||
lcolor.getX11Name(clr).c_str(), xclr);
|
||||
const_cast<char*>(
|
||||
lcolor.getX11Name(clr).c_str())
|
||||
, xclr);
|
||||
colorCache.cacheXftColor(clr, xclr);
|
||||
}
|
||||
return xclr;
|
||||
|
@ -42,6 +42,8 @@ libgtk_la_SOURCES = \
|
||||
Alert_pimpl.C \
|
||||
GView.h \
|
||||
GView.C \
|
||||
IdSc.h \
|
||||
IdSc.C \
|
||||
Dialogs.C \
|
||||
GAboutlyx.h \
|
||||
GAboutlyx.C \
|
||||
@ -54,8 +56,12 @@ libgtk_la_SOURCES = \
|
||||
FileDialog.C \
|
||||
GText.h \
|
||||
GText.C \
|
||||
IdSc.h \
|
||||
IdSc.C
|
||||
GUrl.h \
|
||||
GUrl.C \
|
||||
GTableCreate.h \
|
||||
GTableCreate.C \
|
||||
GMathPanel.h \
|
||||
GMathPanel.C
|
||||
|
||||
# GPrint.h
|
||||
# GPrint.C
|
||||
@ -90,7 +96,6 @@ xforms_objects = \
|
||||
../xforms/FormMathsBitmap.lo \
|
||||
../xforms/FormMathsDelim.lo \
|
||||
../xforms/FormMathsMatrix.lo \
|
||||
../xforms/FormMathsPanel.lo \
|
||||
../xforms/FormMathsSpace.lo \
|
||||
../xforms/FormMathsStyle.lo \
|
||||
../xforms/FormMinipage.lo \
|
||||
@ -105,13 +110,11 @@ xforms_objects = \
|
||||
../xforms/forms_gettext.lo \
|
||||
../xforms/FormShowFile.lo \
|
||||
../xforms/FormSpellchecker.lo \
|
||||
../xforms/FormTabularCreate.lo \
|
||||
../xforms/FormTabular.lo \
|
||||
../xforms/FormTexinfo.lo \
|
||||
../xforms/FormText.lo \
|
||||
../xforms/FormThesaurus.lo \
|
||||
../xforms/FormToc.lo \
|
||||
../xforms/FormUrl.lo \
|
||||
../xforms/FormVCLog.lo \
|
||||
../xforms/FormWrap.lo \
|
||||
../xforms/freebrowser.lo \
|
||||
@ -127,6 +130,9 @@ xforms_objects = \
|
||||
# ../xforms/FormFiledialog.lo
|
||||
# ../xforms/FileDialog.lo
|
||||
# ../xforms/FormAboutlyx.lo
|
||||
# ../xforms/FormUrl.lo
|
||||
# ../xforms/FormTabularCreate.lo
|
||||
# ../xforms/FormMathsPanel.lo
|
||||
|
||||
xforms.lo: $(xforms_objects) ../xforms/forms/*.lo
|
||||
$(CXXLINK) $(xforms_objects) ../xforms/forms/*.lo
|
||||
|
@ -15,21 +15,21 @@
|
||||
#include <X11/Xft/Xft.h>
|
||||
|
||||
|
||||
inline FcChar32 * wcsToFcChar32StrFast(wchar_t * wcs)
|
||||
inline XftChar32 * wcsToXftChar32StrFast(wchar_t * wcs)
|
||||
{
|
||||
return reinterpret_cast<FcChar32*>(wcs);
|
||||
return reinterpret_cast<XftChar32 *>(wcs);
|
||||
}
|
||||
|
||||
|
||||
inline FcChar32 const * wcsToFcChar32StrFast(wchar_t const * wcs)
|
||||
inline XftChar32 * wcsToXftChar32StrFast(wchar_t const * wcs)
|
||||
{
|
||||
return reinterpret_cast<FcChar32 const *>(wcs);
|
||||
return reinterpret_cast<XftChar32 *>(const_cast<wchar_t *>(wcs));
|
||||
}
|
||||
|
||||
|
||||
inline FcChar32 wcToFcChar32(wchar_t wc)
|
||||
inline XftChar32 wcToXftChar32(wchar_t wc)
|
||||
{
|
||||
return static_cast<FcChar32>(wc);
|
||||
return static_cast<XftChar32>(wc);
|
||||
}
|
||||
|
||||
|
||||
|
@ -1,2 +1,3 @@
|
||||
Makefile.in
|
||||
Makefile
|
||||
*.gladep
|
||||
|
525
src/frontends/gtk/glade/mathPanel.glade
Normal file
525
src/frontends/gtk/glade/mathPanel.glade
Normal file
@ -0,0 +1,525 @@
|
||||
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
||||
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
||||
|
||||
<glade-interface>
|
||||
|
||||
<widget class="GtkWindow" id="dialog">
|
||||
<property name="visible">True</property>
|
||||
<property name="title" translatable="yes">LyX: Math Panel</property>
|
||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||
<property name="modal">False</property>
|
||||
<property name="resizable">False</property>
|
||||
<property name="destroy_with_parent">False</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkHBox" id="hbox1">
|
||||
<property name="border_width">5</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">10</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkVBox" id="vbox1">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">20</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTable" id="table1">
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">2</property>
|
||||
<property name="n_columns">5</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="row_spacing">0</property>
|
||||
<property name="column_spacing">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Equation">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">4</property>
|
||||
<property name="right_attach">5</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Matrix">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">3</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Style">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Sub">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Super">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Sqrt">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Frac">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Delim">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Deco">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">3</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Space">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">4</property>
|
||||
<property name="right_attach">5</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTable" id="table2">
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">4</property>
|
||||
<property name="n_columns">3</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="row_spacing">0</property>
|
||||
<property name="column_spacing">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Boperator">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">+*</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Brelate">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes"><-</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Arrow">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">|-</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Dots">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Dots</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Misc">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Misc</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Greek">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Rpeek</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="AmsArrow">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">|-</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="AmsBrel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes"><=</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="AmsOps">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">+*</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="AmsMisc">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Misc</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="AmsNrel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">!(<>)</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="VarSize">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Ef</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkVBox" id="vbox2">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">3</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Functions:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0.5</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkScrolledWindow" id="scrolledwindow1">
|
||||
<property name="border_width">3</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="hscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
||||
<property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
|
||||
<property name="shadow_type">GTK_SHADOW_NONE</property>
|
||||
<property name="window_placement">GTK_CORNER_TOP_LEFT</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTreeView" id="Functions">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="headers_visible">False</property>
|
||||
<property name="rules_hint">False</property>
|
||||
<property name="reorderable">False</property>
|
||||
<property name="enable_search">True</property>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Close">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="has_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-close</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
|
||||
</glade-interface>
|
278
src/frontends/gtk/glade/search.glade
Normal file
278
src/frontends/gtk/glade/search.glade
Normal file
@ -0,0 +1,278 @@
|
||||
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
||||
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
||||
|
||||
<glade-interface>
|
||||
|
||||
<widget class="GtkWindow" id="dialog">
|
||||
<property name="visible">True</property>
|
||||
<property name="title" translatable="yes">LyX: Find and Replace</property>
|
||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||
<property name="modal">False</property>
|
||||
<property name="resizable">True</property>
|
||||
<property name="destroy_with_parent">False</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTable" id="table1">
|
||||
<property name="border_width">5</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">4</property>
|
||||
<property name="n_columns">3</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="row_spacing">2</property>
|
||||
<property name="column_spacing">2</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Find:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label2">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Replace with:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkEntry" id="FindEntry">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="editable">True</property>
|
||||
<property name="visibility">True</property>
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="activates_default">False</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkEntry" id="ReplaceEntry">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="editable">True</property>
|
||||
<property name="visibility">True</property>
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="activates_default">False</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="FindNext">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="has_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Find next</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Replace">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">_Replace</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="ReplaceAll">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Repl_ace all</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Cancel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Cancel</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="right_attach">3</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkHBox" id="hbox1">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="CaseSensitive">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">_Case sensitive</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="MatchWord">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">_Match word</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options">fill</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkHBox" id="hbox2">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="SearchBackwords">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">_Search backwards</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options">fill</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
|
||||
</glade-interface>
|
182
src/frontends/gtk/glade/tableCreate.glade
Normal file
182
src/frontends/gtk/glade/tableCreate.glade
Normal file
@ -0,0 +1,182 @@
|
||||
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
||||
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
||||
|
||||
<glade-interface>
|
||||
|
||||
<widget class="GtkDialog" id="dialog">
|
||||
<property name="visible">True</property>
|
||||
<property name="title" translatable="yes">LyX: Insert Table</property>
|
||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||
<property name="modal">False</property>
|
||||
<property name="resizable">False</property>
|
||||
<property name="destroy_with_parent">False</property>
|
||||
<property name="has_separator">True</property>
|
||||
|
||||
<child internal-child="vbox">
|
||||
<widget class="GtkVBox" id="dialog-vbox1">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">0</property>
|
||||
|
||||
<child internal-child="action_area">
|
||||
<widget class="GtkHButtonBox" id="dialog-action_area1">
|
||||
<property name="visible">True</property>
|
||||
<property name="layout_style">GTK_BUTTONBOX_END</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Ok">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="has_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-ok</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-5</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Apply">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-apply</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-10</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Cancel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-cancel</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-6</property>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="pack_type">GTK_PACK_END</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTable" id="table1">
|
||||
<property name="border_width">5</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">2</property>
|
||||
<property name="n_columns">2</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="row_spacing">5</property>
|
||||
<property name="column_spacing">5</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Rows:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label2">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Columns:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkSpinButton" id="Rows">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="climb_rate">1</property>
|
||||
<property name="digits">0</property>
|
||||
<property name="numeric">False</property>
|
||||
<property name="update_policy">GTK_UPDATE_ALWAYS</property>
|
||||
<property name="snap_to_ticks">False</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="adjustment">5 0 100 1 10 10</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkSpinButton" id="Columns">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="climb_rate">1</property>
|
||||
<property name="digits">0</property>
|
||||
<property name="numeric">False</property>
|
||||
<property name="update_policy">GTK_UPDATE_ALWAYS</property>
|
||||
<property name="snap_to_ticks">False</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="adjustment">5 0 100 1 10 10</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
|
||||
</glade-interface>
|
268
src/frontends/gtk/glade/url.glade
Normal file
268
src/frontends/gtk/glade/url.glade
Normal file
@ -0,0 +1,268 @@
|
||||
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
||||
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
||||
|
||||
<glade-interface>
|
||||
|
||||
<widget class="GtkDialog" id="dialog">
|
||||
<property name="visible">True</property>
|
||||
<property name="title" translatable="yes">LyX: URL</property>
|
||||
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||
<property name="modal">False</property>
|
||||
<property name="resizable">False</property>
|
||||
<property name="destroy_with_parent">False</property>
|
||||
<property name="has_separator">True</property>
|
||||
|
||||
<child internal-child="vbox">
|
||||
<widget class="GtkVBox" id="dialog-vbox1">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">0</property>
|
||||
|
||||
<child internal-child="action_area">
|
||||
<widget class="GtkHButtonBox" id="dialog-action_area1">
|
||||
<property name="visible">True</property>
|
||||
<property name="layout_style">GTK_BUTTONBOX_END</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Restore">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkAlignment" id="alignment1">
|
||||
<property name="visible">True</property>
|
||||
<property name="xalign">0.5</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xscale">0</property>
|
||||
<property name="yscale">0</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkHBox" id="hbox1">
|
||||
<property name="visible">True</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="spacing">2</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkImage" id="image1">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-undo</property>
|
||||
<property name="icon_size">4</property>
|
||||
<property name="xalign">0.5</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label3">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">_Restore</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0.5</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Ok">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-ok</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-5</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Apply">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-apply</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-10</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkButton" id="Cancel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_default">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label">gtk-cancel</property>
|
||||
<property name="use_stock">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="response_id">-6</property>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="pack_type">GTK_PACK_END</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkTable" id="table1">
|
||||
<property name="border_width">5</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">3</property>
|
||||
<property name="n_columns">2</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="row_spacing">5</property>
|
||||
<property name="column_spacing">5</property>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="Html">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">_HTML type</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="bottom_attach">1</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkEntry" id="Url">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="editable">True</property>
|
||||
<property name="visibility">True</property>
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="activates_default">False</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkEntry" id="Name">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="editable">True</property>
|
||||
<property name="visibility">True</property>
|
||||
<property name="max_length">0</property>
|
||||
<property name="text" translatable="yes"></property>
|
||||
<property name="has_frame">True</property>
|
||||
<property name="invisible_char" translatable="yes">*</property>
|
||||
<property name="activates_default">False</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">URL:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="bottom_attach">2</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkLabel" id="label2">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Name:</property>
|
||||
<property name="use_underline">False</property>
|
||||
<property name="use_markup">False</property>
|
||||
<property name="justify">GTK_JUSTIFY_RIGHT</property>
|
||||
<property name="wrap">False</property>
|
||||
<property name="selectable">False</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="yalign">0.5</property>
|
||||
<property name="xpad">0</property>
|
||||
<property name="ypad">0</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="bottom_attach">3</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="padding">0</property>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
</child>
|
||||
</widget>
|
||||
|
||||
</glade-interface>
|
@ -101,7 +101,7 @@ int ascent(wchar_t c,LyXFont const & f)
|
||||
XftFont * font = getXftFont(f);
|
||||
XGlyphInfo glyph;
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(&c),
|
||||
wcsToXftChar32StrFast(&c),
|
||||
1,
|
||||
&glyph);
|
||||
return XGlyphAscent(glyph);
|
||||
@ -119,7 +119,7 @@ int descent(wchar_t c,LyXFont const & f)
|
||||
XftFont * font = getXftFont(f);
|
||||
XGlyphInfo glyph;
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(&c),
|
||||
wcsToXftChar32StrFast(&c),
|
||||
1,
|
||||
&glyph);
|
||||
return XGlyphDescent(glyph);
|
||||
@ -137,7 +137,7 @@ int lbearing(wchar_t c,LyXFont const & f)
|
||||
XftFont * font = getXftFont(f);
|
||||
XGlyphInfo glyph;
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(&c),
|
||||
wcsToXftChar32StrFast(&c),
|
||||
1,
|
||||
&glyph);
|
||||
return XGlyphLbearing(glyph);
|
||||
@ -149,7 +149,7 @@ int rbearing(wchar_t c,LyXFont const & f)
|
||||
XftFont * font = getXftFont(f);
|
||||
XGlyphInfo glyph;
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(&c),
|
||||
wcsToXftChar32StrFast(&c),
|
||||
1,
|
||||
&glyph);
|
||||
return XGlyphRbearing(glyph);
|
||||
@ -174,7 +174,8 @@ int width(wchar_t const * s, size_t n, LyXFont const & f)
|
||||
XGlyphInfo glyph;
|
||||
if (f.realShape() != LyXFont::SMALLCAPS_SHAPE){
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(s),
|
||||
const_cast<XftChar32*>(
|
||||
wcsToXftChar32StrFast(s)),
|
||||
n,
|
||||
&glyph);
|
||||
return XGlyphLogWidth(glyph);
|
||||
@ -187,13 +188,13 @@ int width(wchar_t const * s, size_t n, LyXFont const & f)
|
||||
wchar_t wc = lyx::support::uppercase(s[i]);
|
||||
if (wc != s[i]) {
|
||||
XftTextExtents32(getDisplay(), fontS,
|
||||
wcsToFcChar32StrFast(&wc),
|
||||
wcsToXftChar32StrFast(&wc),
|
||||
1,
|
||||
&glyph);
|
||||
result += XGlyphLogWidth(glyph);
|
||||
} else {
|
||||
XftTextExtents32(getDisplay(), font,
|
||||
wcsToFcChar32StrFast(&wc),
|
||||
wcsToXftChar32StrFast(&wc),
|
||||
1,
|
||||
&glyph);
|
||||
result += XGlyphLogWidth(glyph);
|
||||
|
Loading…
Reference in New Issue
Block a user