mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Added GUII RunTime support and KDE InsetUrl-GUI support from John
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@974 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
578e4fa213
commit
5da9e207fa
34
ChangeLog
34
ChangeLog
@ -1,9 +1,39 @@
|
||||
2000-08-16 Juergen Vigna <jug@sad.it>
|
||||
|
||||
* src/lyx_gui.C (runTime): added GUII RunTime support.
|
||||
|
||||
* src/frontends/Makefile.am:
|
||||
* src/frontends/GUIRunTime.[Ch]:
|
||||
* src/frontends/xforms/GUIRunTime_pimpl.[Ch]:
|
||||
* src/frontends/kde/GUIRunTime_pimpl.[Ch]:
|
||||
* src/frontends/gnome/GUIRunTime_pimpl.[Ch]: added GUII runtime support
|
||||
|
||||
* src/LyXAction.C (init): added dummy LFUN_INSERT_URL.
|
||||
|
||||
* src/frontends/Makefile.am (INCLUDES): don't set the FRONTENDS include
|
||||
as this is already set in ${FRONTEND_INCLUDE} if needed.
|
||||
|
||||
* configure.in (CPPFLAGS): setting the include dir for the frontend
|
||||
directory and don't set FRONTEND=xforms for now as this is executed
|
||||
always.
|
||||
|
||||
2000-08-16 John Levon (moz@compsoc.man.ac.uk)
|
||||
|
||||
* src/frontends/kde/Makefile.am:
|
||||
* src/frontends/kde/FormUrl.C:
|
||||
* src/frontends/kde/FormUrl.h:
|
||||
* src/frontends/kde/formurldialog.h:
|
||||
* src/frontends/kde/formurldialog.C: Add KDE URL dialog
|
||||
|
||||
2000-08-15 Kayvan A. Sylvan <kayvan@sylvan.com>
|
||||
|
||||
* src/frontend/Makefile.am: Add gnome and kde to dist tar file.
|
||||
|
||||
2000-08-16 Lars Gullik Bjønnes <larsbj@lyx.org>
|
||||
|
||||
* src/BufferView_pimpl.C (workAreaKeyPress): enable the
|
||||
processKeySym
|
||||
|
||||
|
||||
2000-08-15 Lars Gullik Bjønnes <larsbj@lyx.org>
|
||||
|
||||
* src/WorkArea.C (work_area_handler): more work to get te
|
||||
@ -772,7 +802,7 @@
|
||||
|
||||
* src/lyxfunc.C (Dispatch) : modified to accomodate new FormToc class
|
||||
and modified InsetTOC class
|
||||
* src/buffer.C: ditto
|
||||
* src/buffer.C: ditto
|
||||
|
||||
* forms/lyx.fd: strip out old FD_form_toc code
|
||||
* src/lyx_gui_misc.C: ditto
|
||||
|
@ -164,11 +164,12 @@ case "$lyx_use_frontend" in
|
||||
FRONTEND="kde"
|
||||
FRONTEND_GUILIB="\${top_builddir}/src/frontends/kde/libkde.la"
|
||||
FRONTEND_LDFLAGS="\$(QT_LDFLAGS) \$(KDE_LDFLAGS)"
|
||||
FRONTEND_INCLUDES="\$(QT_INCLUDES) \$(KDE_INCLUDES)"
|
||||
FRONTEND_INCLUDES="-I\${srcdir}/kde \$(QT_INCLUDES) \$(KDE_INCLUDES)"
|
||||
FRONTEND_LIBS="\$(KDE_LIBS)"
|
||||
AC_DEFINE(KDEGUI);;
|
||||
xforms)
|
||||
FRONTEND="xforms"
|
||||
# for now don't set it for xforms as this is always entered
|
||||
FRONTEND=""
|
||||
FRONTEND_GUILIB="\${top_builddir}/src/frontends/xforms/libxforms.la";;
|
||||
gnome)
|
||||
AM_PATH_GTKMM(1.2.1,,
|
||||
@ -178,7 +179,7 @@ case "$lyx_use_frontend" in
|
||||
FRONTEND="gnome"
|
||||
FRONTEND_GUILIB="\${top_builddir}/src/frontends/gnome/libgnome.la"
|
||||
FRONTEND_LDFLAGS="\$(GNOMEMM_LIBDIR)"
|
||||
FRONTEND_INCLUDES="\$(GNOMEMM_INCLUDEDIR) \$(GTKMM_CFLAGS)"
|
||||
FRONTEND_INCLUDES="-I\${srcdir}/gnome \$(GNOMEMM_INCLUDEDIR) \$(GTKMM_CFLAGS)"
|
||||
FRONTEND_LIBS="\$(GNOMEMM_LIBS) \$(GTKMM_LIBS)"
|
||||
AC_DEFINE(GTKGUI);;
|
||||
*)
|
||||
|
@ -44,6 +44,17 @@ src/frontends/xforms/FormPrint.C
|
||||
src/frontends/xforms/form_print.C
|
||||
src/frontends/xforms/FormRef.C
|
||||
src/frontends/xforms/form_ref.C
|
||||
src/frontends/xforms/forms/form_citation.C
|
||||
src/frontends/xforms/forms/form_copyright.C
|
||||
src/frontends/xforms/forms/form_document.C
|
||||
src/frontends/xforms/forms/form_graphics.C
|
||||
src/frontends/xforms/forms/form_index.C
|
||||
src/frontends/xforms/forms/form_preferences.C
|
||||
src/frontends/xforms/forms/form_print.C
|
||||
src/frontends/xforms/forms/form_ref.C
|
||||
src/frontends/xforms/forms/form_tabular.C
|
||||
src/frontends/xforms/forms/form_toc.C
|
||||
src/frontends/xforms/forms/form_url.C
|
||||
src/frontends/xforms/FormTabular.C
|
||||
src/frontends/xforms/form_tabular.C
|
||||
src/frontends/xforms/FormToc.C
|
||||
|
@ -405,6 +405,7 @@ void LyXAction::init()
|
||||
{ LFUN_UP, "up", "", ReadOnly },
|
||||
{ LFUN_UPSEL, "up-select", "", ReadOnly },
|
||||
{ LFUN_URL, "url-insert", "", Noop },
|
||||
{ LFUN_INSERT_URL, "", "", Noop },
|
||||
{ LFUN_VC_CHECKIN, "vc-check-in", "", ReadOnly },
|
||||
{ LFUN_VC_CHECKOUT, "vc-check-out", "", ReadOnly },
|
||||
{ LFUN_VC_HISTORY, "vc-history", "", ReadOnly },
|
||||
|
@ -165,17 +165,18 @@ _("Credits...|e");
|
||||
_("Version...|V");
|
||||
_("");
|
||||
_("A&A");
|
||||
_("ACT");
|
||||
_("AT_RISE:");
|
||||
_("Abstract");
|
||||
_("Accepted");
|
||||
_("Acknowledgement");
|
||||
_("Acknowledgement(s)");
|
||||
_("Acknowledgement*");
|
||||
_("Acknowledgement-numbered");
|
||||
_("Acknowledgement(s)");
|
||||
_("Acknowledgements");
|
||||
_("Acknowledgement-unnumbered");
|
||||
_("Acknowledgements");
|
||||
_("Acknowledgments");
|
||||
_("Acnowledgement");
|
||||
_("ACT");
|
||||
_("Addchap");
|
||||
_("Addchap*");
|
||||
_("Addition");
|
||||
@ -193,15 +194,15 @@ _("Anlagen");
|
||||
_("Anrede");
|
||||
_("Appendices");
|
||||
_("Appendix");
|
||||
_("AT_RISE:");
|
||||
_("Author");
|
||||
_("AuthorRunning");
|
||||
_("Author_Email");
|
||||
_("Author_Running");
|
||||
_("AuthorRunning");
|
||||
_("Author_URL");
|
||||
_("Axiom");
|
||||
_("Axiom-numbered");
|
||||
_("Axiom-plain");
|
||||
_("BLZ");
|
||||
_("Backaddress");
|
||||
_("Bank");
|
||||
_("BankAccount");
|
||||
@ -209,13 +210,12 @@ _("BankCode");
|
||||
_("Betreff");
|
||||
_("Bibliography");
|
||||
_("Biography");
|
||||
_("BLZ");
|
||||
_("Brieftext");
|
||||
_("CC");
|
||||
_("CURTAIN");
|
||||
_("Caption");
|
||||
_("Case");
|
||||
_("Case-numbered");
|
||||
_("CC");
|
||||
_("cc");
|
||||
_("CenteredCaption");
|
||||
_("Chapter");
|
||||
_("Chapter*");
|
||||
@ -255,7 +255,6 @@ _("Criterion-plain");
|
||||
_("CrossList");
|
||||
_("Current");
|
||||
_("Current_Address");
|
||||
_("CURTAIN");
|
||||
_("Customer");
|
||||
_("Data");
|
||||
_("Date");
|
||||
@ -270,10 +269,10 @@ _("Definition-unnumbered");
|
||||
_("Description");
|
||||
_("Dialogue");
|
||||
_("EMail");
|
||||
_("EXT.");
|
||||
_("Email");
|
||||
_("Encl");
|
||||
_("Encl.");
|
||||
_("encl");
|
||||
_("End_All_Slides");
|
||||
_("Enumerate");
|
||||
_("Example");
|
||||
@ -284,48 +283,43 @@ _("Example-unnumbered");
|
||||
_("Exercise");
|
||||
_("Exercise-numbered");
|
||||
_("Exercise-plain");
|
||||
_("EXT.");
|
||||
_("Extratitle");
|
||||
_("FADE_IN:");
|
||||
_("FADE_OUT:");
|
||||
_("Fact");
|
||||
_("Fact*");
|
||||
_("Fact-numbered");
|
||||
_("Fact-plain");
|
||||
_("Fact-unnumbered");
|
||||
_("FADE_IN:");
|
||||
_("FADE_OUT:");
|
||||
_("FigCaption");
|
||||
_("first");
|
||||
_("FirstAuthor");
|
||||
_("FirstName");
|
||||
_("FitBitmap");
|
||||
_("FitFigure");
|
||||
_("Foilhead");
|
||||
_("foilhead");
|
||||
_("Footernote");
|
||||
_("FourAffiliations");
|
||||
_("FourAuthors");
|
||||
_("Gruss");
|
||||
_("Headnote");
|
||||
_("HTTP");
|
||||
_("Headnote");
|
||||
_("INT.");
|
||||
_("Idea");
|
||||
_("IhrSchreiben");
|
||||
_("IhrZeichen");
|
||||
_("Institute");
|
||||
_("Institution");
|
||||
_("INT.");
|
||||
_("InvisibleText");
|
||||
_("Invoice");
|
||||
_("Itemize");
|
||||
_("Journal");
|
||||
_("journal");
|
||||
_("Keywords");
|
||||
_("Konto");
|
||||
_("Labeling");
|
||||
_("Land");
|
||||
_("landscape");
|
||||
_("LandscapeSlide");
|
||||
_("LaTeX");
|
||||
_("LaTeX_Title");
|
||||
_("Labeling");
|
||||
_("Land");
|
||||
_("LandscapeSlide");
|
||||
_("Lemma");
|
||||
_("Lemma*");
|
||||
_("Lemma-numbered");
|
||||
@ -344,10 +338,8 @@ _("MarkBoth");
|
||||
_("MathLetters");
|
||||
_("MeinZeichen");
|
||||
_("Minisec");
|
||||
_("modying");
|
||||
_("msnumber");
|
||||
_("My_Address");
|
||||
_("MyRef");
|
||||
_("My_Address");
|
||||
_("Myref");
|
||||
_("Name");
|
||||
_("Narrative");
|
||||
@ -357,18 +349,18 @@ _("Note");
|
||||
_("Note*");
|
||||
_("Note-numbered");
|
||||
_("Note-plain");
|
||||
_("Note-unnumbered");
|
||||
_("NoteToEditor");
|
||||
_("Notetoeditor");
|
||||
_("Note-unnumbered");
|
||||
_("Offprint");
|
||||
_("Offprints");
|
||||
_("Offsets");
|
||||
_("offsets");
|
||||
_("Oggetto");
|
||||
_("Opening");
|
||||
_("Ort");
|
||||
_("Overlay");
|
||||
_("PACS");
|
||||
_("PS");
|
||||
_("Paragraph");
|
||||
_("Paragraph*");
|
||||
_("Paragraph-numbered");
|
||||
@ -379,8 +371,8 @@ _("Petit");
|
||||
_("Phone");
|
||||
_("Place");
|
||||
_("PlaceFigure");
|
||||
_("Placefigure");
|
||||
_("PlaceTable");
|
||||
_("Placefigure");
|
||||
_("Placetable");
|
||||
_("PortraitSlide");
|
||||
_("PostalCommend");
|
||||
@ -397,12 +389,11 @@ _("Proposition*");
|
||||
_("Proposition-numbered");
|
||||
_("Proposition-plain");
|
||||
_("Proposition-unnumbered");
|
||||
_("PS");
|
||||
_("ps");
|
||||
_("Publishers");
|
||||
_("Question");
|
||||
_("Quotation");
|
||||
_("Quote");
|
||||
_("REVTEX_Title");
|
||||
_("Received");
|
||||
_("Recieved");
|
||||
_("Recieved/Accepted");
|
||||
@ -412,17 +403,17 @@ _("Remark");
|
||||
_("Remark*");
|
||||
_("Remark-numbered");
|
||||
_("Remark-plain");
|
||||
_("Remarks");
|
||||
_("Remark-unnumbered");
|
||||
_("Remarks");
|
||||
_("RetourAdresse");
|
||||
_("ReturnAddress");
|
||||
_("REVTEX_Title");
|
||||
_("Right_Address");
|
||||
_("RightHeader");
|
||||
_("Right_Address");
|
||||
_("Rotatefoilhead");
|
||||
_("Running_LaTeX_Title");
|
||||
_("SCENE");
|
||||
_("SCENE*");
|
||||
_("SGML");
|
||||
_("Scrap");
|
||||
_("Section");
|
||||
_("Section*");
|
||||
@ -430,11 +421,10 @@ _("Section-numbered");
|
||||
_("Send");
|
||||
_("Send_To_Address");
|
||||
_("Seriate");
|
||||
_("SGML");
|
||||
_("ShortFoilhead");
|
||||
_("Shortfoilhead");
|
||||
_("ShortRotatefoilhead");
|
||||
_("ShortTitle");
|
||||
_("Shortfoilhead");
|
||||
_("Signature");
|
||||
_("Slide");
|
||||
_("Slide*");
|
||||
@ -450,26 +440,26 @@ _("State");
|
||||
_("Strasse");
|
||||
_("Street");
|
||||
_("Style");
|
||||
_("style");
|
||||
_("SubSection");
|
||||
_("SubTitle");
|
||||
_("Subitle");
|
||||
_("Subject");
|
||||
_("Subjectclass");
|
||||
_("Subparagraph");
|
||||
_("Subparagraph*");
|
||||
_("SubSection");
|
||||
_("Subsection");
|
||||
_("Subsection*");
|
||||
_("Subsection-numbered");
|
||||
_("Subsubsection");
|
||||
_("Subsubsection*");
|
||||
_("Subsubsection-numbered");
|
||||
_("SubTitle");
|
||||
_("Subtitle");
|
||||
_("Suggested");
|
||||
_("Summary");
|
||||
_("Summary-numbered");
|
||||
_("Surname");
|
||||
_("surname");
|
||||
_("TOC_Author");
|
||||
_("TOC_Title");
|
||||
_("TableComments");
|
||||
_("TableRefs");
|
||||
_("Telefax");
|
||||
@ -481,8 +471,8 @@ _("Theorem");
|
||||
_("Theorem*");
|
||||
_("Theorem-numbered");
|
||||
_("Theorem-plain");
|
||||
_("TheoremTemplate");
|
||||
_("Theorem-unnumbered");
|
||||
_("TheoremTemplate");
|
||||
_("Thesaurus");
|
||||
_("ThickLine");
|
||||
_("This");
|
||||
@ -490,29 +480,39 @@ _("ThreeAffiliations");
|
||||
_("ThreeAuthors");
|
||||
_("TickList");
|
||||
_("Title");
|
||||
_("Titlehead");
|
||||
_("Title_Running");
|
||||
_("TOC_Author");
|
||||
_("TOC_Title");
|
||||
_("Titlehead");
|
||||
_("Town");
|
||||
_("Transition");
|
||||
_("Trans_Keywords");
|
||||
_("Transition");
|
||||
_("Translated");
|
||||
_("TranslatedAbstract");
|
||||
_("Translated_Title");
|
||||
_("Translator");
|
||||
_("TwoAffiliations");
|
||||
_("TwoAuthors");
|
||||
_("URL");
|
||||
_("Unterschrift");
|
||||
_("Uppertitleback");
|
||||
_("URL");
|
||||
_("Use");
|
||||
_("Verbatim");
|
||||
_("Verse");
|
||||
_("Verteiler");
|
||||
_("VisibleText");
|
||||
_("YourMail");
|
||||
_("Yourmail");
|
||||
_("YourRef");
|
||||
_("Yourmail");
|
||||
_("Yourref");
|
||||
_("Zusatz");
|
||||
_("cc");
|
||||
_("encl");
|
||||
_("first");
|
||||
_("foilhead");
|
||||
_("journal");
|
||||
_("landscape");
|
||||
_("modying");
|
||||
_("msnumber");
|
||||
_("offsets");
|
||||
_("ps");
|
||||
_("style");
|
||||
_("surname");
|
||||
|
37
src/frontends/GUIRunTime.C
Normal file
37
src/frontends/GUIRunTime.C
Normal file
@ -0,0 +1,37 @@
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
* ====================================================== */
|
||||
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#include "GUIRunTime.h"
|
||||
#include "GUIRunTime_pimpl.h"
|
||||
|
||||
GUIRunTime::GUIRunTime()
|
||||
{
|
||||
pimpl_ = new Pimpl();
|
||||
}
|
||||
|
||||
|
||||
GUIRunTime::~GUIRunTime()
|
||||
{
|
||||
delete pimpl_;
|
||||
}
|
||||
|
||||
|
||||
void GUIRunTime::processEvents()
|
||||
{
|
||||
pimpl_->processEvents();
|
||||
}
|
40
src/frontends/GUIRunTime.h
Normal file
40
src/frontends/GUIRunTime.h
Normal file
@ -0,0 +1,40 @@
|
||||
// -*- C++ -*-
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
* ====================================================== */
|
||||
|
||||
#ifndef GUIRUNTIME_H
|
||||
#define GUIRUNTIME_H
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma interface
|
||||
#endif
|
||||
|
||||
class LyXView;
|
||||
|
||||
/** The LyX GUI independent guiruntime class
|
||||
The GUI interface is implemented in the corresponding GUIRunTime_pimpl class.
|
||||
*/
|
||||
class GUIRunTime {
|
||||
public:
|
||||
///
|
||||
GUIRunTime();
|
||||
///
|
||||
~GUIRunTime();
|
||||
///
|
||||
void processEvents();
|
||||
|
||||
struct Pimpl;
|
||||
friend struct Pimpl;
|
||||
|
||||
private:
|
||||
Pimpl * pimpl_;
|
||||
};
|
||||
#endif
|
@ -6,7 +6,7 @@ MAINTAINERCLEANFILES = $(srcdir)/Makefile.in
|
||||
# here.
|
||||
SUBDIRS = xforms @FRONTEND@
|
||||
ETAGS_ARGS = --lang=c++
|
||||
INCLUDES = ${FRONTEND_INCLUDES} -I${srcdir}/.. -I${srcdir}/@FRONTEND@ -I${srcdir}/xforms ${SIGC_CFLAGS}
|
||||
INCLUDES = ${FRONTEND_INCLUDES} -I${srcdir}/.. -I${srcdir}/xforms ${SIGC_CFLAGS}
|
||||
LIBS =
|
||||
noinst_LTLIBRARIES = libfrontends.la
|
||||
libfrontends_la_SOURCES=\
|
||||
@ -14,6 +14,8 @@ libfrontends_la_SOURCES=\
|
||||
ButtonPolicies.h \
|
||||
Dialogs.h \
|
||||
DialogBase.h \
|
||||
GUIRunTime.C \
|
||||
GUIRunTime.h \
|
||||
Liason.C \
|
||||
Liason.h \
|
||||
Menubar.C \
|
||||
@ -21,3 +23,8 @@ libfrontends_la_SOURCES=\
|
||||
Toolbar.C \
|
||||
Toolbar.h
|
||||
|
||||
EXTRA_DIST = kde gnome
|
||||
|
||||
dist-hook:
|
||||
@cd $(distdir) ; rm -rf `find kde -name \*CVS\*`; \
|
||||
rm -rf `find gnome -name \*CVS\*`
|
||||
|
35
src/frontends/gnome/GUIRunTime_pimpl.C
Normal file
35
src/frontends/gnome/GUIRunTime_pimpl.C
Normal file
@ -0,0 +1,35 @@
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright (C) 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
*======================================================*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#include "GUIRunTime_pimpl.h"
|
||||
#include <gnome--/main.h>
|
||||
|
||||
using std::endl;
|
||||
|
||||
GUIRunTime::Pimpl::Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
GUIRunTime::Pimpl::~Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
void GUIRunTime::Pimpl::processEvents()
|
||||
{
|
||||
while(Gnome::Main::instance()->events_pending())
|
||||
Gnome::Main::instance()->iteration(FALSE);
|
||||
}
|
36
src/frontends/gnome/GUIRunTime_pimpl.h
Normal file
36
src/frontends/gnome/GUIRunTime_pimpl.h
Normal file
@ -0,0 +1,36 @@
|
||||
// -*- C++ -*-
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
* ====================================================== */
|
||||
|
||||
#ifndef GUIRUNTIME_PIMPL_H
|
||||
#define GUIRUNTIME_PIMPL_H
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma interface
|
||||
#endif
|
||||
|
||||
#include "frontends/GUIRunTime.h"
|
||||
|
||||
/*
|
||||
* The GUI interface for runtime GUI stuff.
|
||||
*/
|
||||
struct GUIRunTime::Pimpl {
|
||||
public:
|
||||
///
|
||||
Pimpl();
|
||||
///
|
||||
~Pimpl();
|
||||
///
|
||||
void processEvents();
|
||||
|
||||
private:
|
||||
};
|
||||
#endif
|
@ -32,6 +32,8 @@ LYXDATADIRS =
|
||||
#ETAGS_ARGS = --lang=c++
|
||||
libgnome_la_SOURCES = \
|
||||
Dialogs.C \
|
||||
GUIRunTime_pimpl.C \
|
||||
GUIRunTime_pimpl.h \
|
||||
FormCopyright.C \
|
||||
FormCopyright.h \
|
||||
FormPrint.C \
|
||||
|
143
src/frontends/kde/FormUrl.C
Normal file
143
src/frontends/kde/FormUrl.C
Normal file
@ -0,0 +1,143 @@
|
||||
# /*
|
||||
* FormUrl.C
|
||||
* (C) 2000 John Levon
|
||||
* moz@compsoc.man.ac.uk
|
||||
*/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "Dialogs.h"
|
||||
#include "FormUrl.h"
|
||||
#include "gettext.h"
|
||||
#include "buffer.h"
|
||||
#include "LyXView.h"
|
||||
#include "lyxfunc.h"
|
||||
#include "formurldialog.h"
|
||||
|
||||
FormUrl::FormUrl(LyXView *v, Dialogs *d)
|
||||
: dialog_(0), lv_(v), d_(d), inset_(0), h_(0), u_(0), ih_(0)
|
||||
{
|
||||
// let the dialog be shown
|
||||
// This is a permanent connection so we won't bother
|
||||
// storing a copy because we won't be disconnecting.
|
||||
d->showUrl.connect(slot(this, &FormUrl::showUrl));
|
||||
d->createUrl.connect(slot(this, &FormUrl::createUrl));
|
||||
}
|
||||
|
||||
FormUrl::~FormUrl()
|
||||
{
|
||||
delete dialog_;
|
||||
}
|
||||
|
||||
void FormUrl::showUrl(InsetCommand * const inset)
|
||||
{
|
||||
// FIXME: when could inset be 0 here ?
|
||||
if (inset==0)
|
||||
return;
|
||||
|
||||
inset_ = inset;
|
||||
readonly = lv_->buffer()->isReadonly();
|
||||
ih_ = inset_->hide.connect(slot(this,&FormUrl::hide));
|
||||
params = inset->params();
|
||||
|
||||
show();
|
||||
}
|
||||
|
||||
void FormUrl::createUrl(string const & arg)
|
||||
{
|
||||
// we could already be showing a URL, clear it out
|
||||
if (inset_)
|
||||
close();
|
||||
|
||||
readonly = lv_->buffer()->isReadonly();
|
||||
params.setFromString(arg);
|
||||
show();
|
||||
}
|
||||
|
||||
void FormUrl::update()
|
||||
{
|
||||
dialog_->url->setText(params.getContents().c_str());
|
||||
dialog_->urlname->setText(params.getOptions().c_str());
|
||||
|
||||
if (params.getCmdName()=="url")
|
||||
dialog_->htmlurl->setChecked(0);
|
||||
else
|
||||
dialog_->htmlurl->setChecked(1);
|
||||
|
||||
if (readonly) {
|
||||
dialog_->urlname->setFocusPolicy(QWidget::NoFocus);
|
||||
dialog_->url->setFocusPolicy(QWidget::NoFocus);
|
||||
dialog_->buttonOk->hide();
|
||||
dialog_->buttonCancel->setText(_("Close"));
|
||||
dialog_->htmlurl->setEnabled(false);
|
||||
} else {
|
||||
dialog_->urlname->setFocusPolicy(QWidget::StrongFocus);
|
||||
dialog_->url->setFocusPolicy(QWidget::StrongFocus);
|
||||
dialog_->url->setFocus();
|
||||
dialog_->buttonOk->show();
|
||||
dialog_->buttonCancel->setText(_("Cancel"));
|
||||
dialog_->htmlurl->setEnabled(true);
|
||||
}
|
||||
}
|
||||
|
||||
void FormUrl::apply()
|
||||
{
|
||||
if (readonly)
|
||||
return;
|
||||
|
||||
params.setContents(dialog_->url->text());
|
||||
params.setOptions(dialog_->urlname->text());
|
||||
|
||||
if (dialog_->htmlurl->isChecked())
|
||||
params.setCmdName("htmlurl");
|
||||
else
|
||||
params.setCmdName("url");
|
||||
|
||||
if (inset_ != 0) {
|
||||
if (params != inset_->params()) {
|
||||
inset_->setParams(params);
|
||||
lv_->view()->updateInset(inset_, true);
|
||||
}
|
||||
} else
|
||||
lv_->getLyXFunc()->Dispatch(LFUN_INSERT_URL, params.getAsString().c_str());
|
||||
}
|
||||
|
||||
void FormUrl::show()
|
||||
{
|
||||
if (!dialog_)
|
||||
dialog_ = new FormUrlDialog(this, 0, _("LyX: Url"), false);
|
||||
|
||||
if (!dialog_->isVisible()) {
|
||||
h_ = d_->hideBufferDependent.connect(slot(this, &FormUrl::hide));
|
||||
u_ = d_->updateBufferDependent.connect(slot(this, &FormUrl::update));
|
||||
}
|
||||
|
||||
dialog_->raise();
|
||||
dialog_->setActiveWindow();
|
||||
|
||||
update();
|
||||
dialog_->show();
|
||||
}
|
||||
|
||||
void FormUrl::close()
|
||||
{
|
||||
h_.disconnect();
|
||||
u_.disconnect();
|
||||
ih_.disconnect();
|
||||
inset_ = 0;
|
||||
}
|
||||
|
||||
void FormUrl::hide()
|
||||
{
|
||||
dialog_->hide();
|
||||
close();
|
||||
}
|
80
src/frontends/kde/FormUrl.h
Normal file
80
src/frontends/kde/FormUrl.h
Normal file
@ -0,0 +1,80 @@
|
||||
/* FormUrl.h
|
||||
* (C) 2000 John Levon
|
||||
* moz@compsoc.man.ac.uk
|
||||
*/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef FORMURL_H
|
||||
#define FORMURL_H
|
||||
|
||||
#include "DialogBase.h"
|
||||
#include "LString.h"
|
||||
#include "support/utility.hpp"
|
||||
#include "insets/inseturl.h"
|
||||
|
||||
class Dialogs;
|
||||
class LyXView;
|
||||
class FormUrlDialog;
|
||||
|
||||
class FormUrl : public DialogBase, public noncopyable {
|
||||
public:
|
||||
/**@name Constructors and Destructors */
|
||||
//@{
|
||||
///
|
||||
FormUrl(LyXView *, Dialogs *);
|
||||
///
|
||||
~FormUrl();
|
||||
//@}
|
||||
|
||||
/// Apply changes
|
||||
void apply();
|
||||
/// close the connections
|
||||
void close();
|
||||
|
||||
private:
|
||||
/// Create the dialog if necessary, update it and display it.
|
||||
void show();
|
||||
/// Hide the dialog.
|
||||
void hide();
|
||||
/// Update the dialog.
|
||||
void update();
|
||||
|
||||
/// create a URL inset
|
||||
void createUrl(string const &);
|
||||
/// edit a URL inset
|
||||
void showUrl(InsetCommand * const);
|
||||
|
||||
/// Real GUI implementation.
|
||||
FormUrlDialog * dialog_;
|
||||
|
||||
/// the LyXView we belong to
|
||||
LyXView * lv_;
|
||||
|
||||
/** Which Dialogs do we belong to?
|
||||
Used so we can get at the signals we have to connect to.
|
||||
*/
|
||||
Dialogs * d_;
|
||||
/// pointer to the inset if any
|
||||
InsetCommand * inset_;
|
||||
/// insets params
|
||||
InsetCommandParams params;
|
||||
/// is the inset we are reading from a readonly buffer
|
||||
bool readonly;
|
||||
|
||||
/// Hide connection.
|
||||
Connection h_;
|
||||
/// Update connection.
|
||||
Connection u_;
|
||||
/// Inset hide connection.
|
||||
Connection ih_;
|
||||
};
|
||||
|
||||
#endif
|
34
src/frontends/kde/GUIRunTime_pimpl.C
Normal file
34
src/frontends/kde/GUIRunTime_pimpl.C
Normal file
@ -0,0 +1,34 @@
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright (C) 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
*======================================================*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#include "GUIRunTime_pimpl.h"
|
||||
#include <kapp.h>
|
||||
|
||||
using std::endl;
|
||||
|
||||
GUIRunTime::Pimpl::Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
GUIRunTime::Pimpl::~Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
void GUIRunTime::Pimpl::processEvents()
|
||||
{
|
||||
kapp->processEvents();
|
||||
}
|
36
src/frontends/kde/GUIRunTime_pimpl.h
Normal file
36
src/frontends/kde/GUIRunTime_pimpl.h
Normal file
@ -0,0 +1,36 @@
|
||||
// -*- C++ -*-
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
* ====================================================== */
|
||||
|
||||
#ifndef GUIRUNTIME_PIMPL_H
|
||||
#define GUIRUNTIME_PIMPL_H
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma interface
|
||||
#endif
|
||||
|
||||
#include "frontends/GUIRunTime.h"
|
||||
|
||||
/*
|
||||
* The GUI interface for runtime GUI stuff.
|
||||
*/
|
||||
struct GUIRunTime::Pimpl {
|
||||
public:
|
||||
///
|
||||
Pimpl();
|
||||
///
|
||||
~Pimpl();
|
||||
///
|
||||
void processEvents();
|
||||
|
||||
private:
|
||||
};
|
||||
#endif
|
@ -2,10 +2,13 @@ AUTOMAKE_OPTIONS = foreign 1.4
|
||||
MAINTAINERCLEANFILES = $(srcdir)/Makefile.in
|
||||
noinst_LTLIBRARIES = libkde.la
|
||||
INCLUDES = -I${top_srcdir}/src/ -I${top_srcdir}/src/frontends/ \
|
||||
${SIGC_CFLAGS} ${FRONTEND_INCLUDES} -I${top_srcdir}/src/frontends/xforms
|
||||
${SIGC_CFLAGS} ${FRONTEND_INCLUDES} \
|
||||
-I${top_srcdir}/src/frontends/xforms
|
||||
|
||||
# just to make sure, automake makes them
|
||||
BUILTSOURCES = formcopyrightdialog_moc.C
|
||||
BUILTSOURCES = formcopyrightdialog_moc.C \
|
||||
formurldialog_moc.C
|
||||
|
||||
DISTCLEANFILES = $(BUILTSOURCES) *.orig *.rej *~ *.bak core
|
||||
|
||||
libkde_la_OBJADD = \
|
||||
@ -28,8 +31,6 @@ libkde_la_OBJADD = \
|
||||
../xforms/form_tabular.lo \
|
||||
../xforms/FormToc.lo \
|
||||
../xforms/form_toc.lo \
|
||||
../xforms/FormUrl.lo \
|
||||
../xforms/form_url.lo \
|
||||
../xforms/input_validators.lo \
|
||||
../xforms/RadioButtonGroup.lo \
|
||||
../xforms/Toolbar_pimpl.lo \
|
||||
@ -41,11 +42,17 @@ LYXDATADIRS = dlg
|
||||
ETAGS_ARGS = --lang=c++
|
||||
libkde_la_SOURCES = \
|
||||
Dialogs.C \
|
||||
GUIRunTime_pimpl.C \
|
||||
GUIRunTime_pimpl.h \
|
||||
FormCopyright.C \
|
||||
FormCopyright.h \
|
||||
formcopyrightdialog.C \
|
||||
formcopyrightdialog.h \
|
||||
formcopyrightdialogdata.C \
|
||||
FormUrl.C \
|
||||
FormUrl.h \
|
||||
formurldialog.C \
|
||||
formurldialog.h \
|
||||
$(BUILTSOURCES)
|
||||
|
||||
# These still have to be added. Sooner or later. ARRae-20000129
|
||||
@ -75,3 +82,7 @@ dist-hook:
|
||||
formcopyrightdialog.C:formcopyrightdialog_moc.C
|
||||
formcopyrightdialog_moc.C: formcopyrightdialog.h
|
||||
$(MOC) formcopyrightdialog.h -o formcopyrightdialog_moc.C
|
||||
|
||||
formurldialog.C: formurldialog_moc.C
|
||||
formurldialog_moc.C: formurldialog.h
|
||||
$(MOC) formurldialog.h -o formurldialog_moc.C
|
||||
|
@ -5,10 +5,10 @@
|
||||
//
|
||||
data Information
|
||||
{
|
||||
Filename="/nfs/sinco/source/lyx/rae/src/frontends/kde/dlg/formcopyrightdialog.kdevdlg"
|
||||
KDevelopVersion="0.4"
|
||||
Filename="/sinco/source/lyx/lyx-devel/src/frontends/kde/dlg/formcopyrightdialog.kdevdlg"
|
||||
KDevelopVersion="1.1"
|
||||
DlgEditVersion="0.1alpha"
|
||||
LastChanged="Mon Feb 7 12:39:07 2000"
|
||||
LastChanged="Wed Aug 16 15:45:09 2000"
|
||||
}
|
||||
|
||||
data SessionManagement
|
||||
@ -30,6 +30,7 @@ item QWidget
|
||||
Height="400"
|
||||
MinWidth="0"
|
||||
MinHeight="0"
|
||||
IsFixedSize="true"
|
||||
|
||||
item QLabel
|
||||
{
|
||||
|
@ -1,8 +1,6 @@
|
||||
/**********************************************************************
|
||||
--- KDevelop (KDlgEdit) generated file ---
|
||||
|
||||
Last generated: Mon Feb 7 12:39:05 2000
|
||||
|
||||
DO NOT EDIT!!! This file will be automatically
|
||||
regenerated by KDevelop. All changes will be lost.
|
||||
|
||||
@ -12,6 +10,7 @@
|
||||
void FormCopyrightDialog::initDialog(){
|
||||
this->resize(400,400);
|
||||
this->setMinimumSize(0,0);
|
||||
this->setFixedSize(400,400);
|
||||
labelWho= new QLabel(this,"NoName");
|
||||
labelWho->setGeometry(10,10,380,50);
|
||||
labelWho->setMinimumSize(0,0);
|
||||
|
114
src/frontends/kde/formurldialog.C
Normal file
114
src/frontends/kde/formurldialog.C
Normal file
@ -0,0 +1,114 @@
|
||||
/*
|
||||
* formurldialog.C
|
||||
* (C) 2000 John Levon
|
||||
* moz@compsoc.man.ac.uk
|
||||
*/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include "formurldialog.h"
|
||||
|
||||
FormUrlDialog::FormUrlDialog(FormUrl *form, QWidget *parent, const char *name, bool, WFlags)
|
||||
: QDialog(parent,name,false), form_(form)
|
||||
{
|
||||
setCaption(name);
|
||||
|
||||
// widgets
|
||||
|
||||
url = new QLineEdit(this);
|
||||
url->setMinimumSize(url->sizeHint());
|
||||
|
||||
urlname = new QLineEdit(this);
|
||||
urlname->setMinimumSize(urlname->sizeHint());
|
||||
|
||||
labelurl = new QLabel(this);
|
||||
labelurl->setText(_("Url :"));
|
||||
labelurl->setMargin(5);
|
||||
labelurl->setMinimumSize(labelurl->sizeHint());
|
||||
labelurl->setMaximumSize(labelurl->sizeHint());
|
||||
|
||||
labelurlname = new QLabel(this);
|
||||
labelurlname->setText(_("Name :"));
|
||||
labelurlname->setMargin(5);
|
||||
labelurlname->setMinimumSize(labelurlname->sizeHint());
|
||||
labelurlname->setMaximumSize(labelurlname->sizeHint());
|
||||
|
||||
htmlurl = new QCheckBox(this);
|
||||
htmlurl->setText(_("Generate hyperlink"));
|
||||
htmlurl->setMinimumSize(htmlurl->sizeHint());
|
||||
htmlurl->setMaximumSize(htmlurl->sizeHint());
|
||||
|
||||
buttonOk = new QPushButton(this);
|
||||
buttonOk->setMinimumSize(buttonOk->sizeHint());
|
||||
buttonOk->setMaximumSize(buttonOk->sizeHint());
|
||||
buttonOk->setText(_("OK"));
|
||||
buttonOk->setDefault(true);
|
||||
|
||||
buttonCancel = new QPushButton(this);
|
||||
buttonCancel->setMinimumSize(buttonCancel->sizeHint());
|
||||
buttonCancel->setMaximumSize(buttonCancel->sizeHint());
|
||||
buttonCancel->setText(_("Cancel"));
|
||||
|
||||
// tooltips
|
||||
|
||||
QToolTip::add(labelurl,_("URL"));
|
||||
QToolTip::add(url,_("URL"));
|
||||
QToolTip::add(labelurlname,_("Name associated with the URL"));
|
||||
QToolTip::add(urlname,_("Name associated with the URL"));
|
||||
QToolTip::add(htmlurl,_("Output as a hyperlink ?"));
|
||||
|
||||
// layouts
|
||||
|
||||
topLayout = new QHBoxLayout(this,10);
|
||||
|
||||
layout = new QVBoxLayout();
|
||||
topLayout->addLayout(layout);
|
||||
layout->addSpacing(10);
|
||||
|
||||
urlLayout = new QHBoxLayout();
|
||||
layout->addLayout(urlLayout);
|
||||
urlLayout->addWidget(labelurl, 0);
|
||||
urlLayout->addWidget(url, 1);
|
||||
|
||||
urlnameLayout = new QHBoxLayout();
|
||||
layout->addLayout(urlnameLayout);
|
||||
urlnameLayout->addWidget(labelurlname, 0);
|
||||
urlnameLayout->addWidget(urlname, 1);
|
||||
|
||||
htmlurlLayout = new QHBoxLayout();
|
||||
layout->addStretch(1);
|
||||
layout->addLayout(htmlurlLayout);
|
||||
layout->addStretch(1);
|
||||
htmlurlLayout->addWidget(htmlurl);
|
||||
htmlurlLayout->addStretch(1);
|
||||
|
||||
buttonLayout = new QHBoxLayout();
|
||||
layout->addLayout(buttonLayout);
|
||||
buttonLayout->addStretch(1);
|
||||
buttonLayout->addWidget(buttonOk, 1);
|
||||
buttonLayout->addStretch(2);
|
||||
buttonLayout->addWidget(buttonCancel, 1);
|
||||
buttonLayout->addStretch(1);
|
||||
|
||||
// connections
|
||||
|
||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(apply_gate()));
|
||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(close_gate()));
|
||||
}
|
||||
|
||||
void FormUrlDialog::closeEvent(QCloseEvent *e)
|
||||
{
|
||||
form_->close();
|
||||
e->accept();
|
||||
}
|
||||
|
||||
FormUrlDialog::~FormUrlDialog()
|
||||
{
|
||||
}
|
80
src/frontends/kde/formurldialog.h
Normal file
80
src/frontends/kde/formurldialog.h
Normal file
@ -0,0 +1,80 @@
|
||||
/*
|
||||
* formurldialog.h
|
||||
* (C) 2000 John Levon
|
||||
* moz@compsoc.man.ac.uk
|
||||
*/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef FORMURLDIALOG_H
|
||||
#define FORMURLDIALOG_H
|
||||
|
||||
#include <config.h>
|
||||
#include <gettext.h>
|
||||
|
||||
// to connect apply() and hide()
|
||||
#include "FormUrl.h"
|
||||
|
||||
#include <qdialog.h>
|
||||
#include <qlayout.h>
|
||||
#include <qlabel.h>
|
||||
#include <qtooltip.h>
|
||||
#include <qcheckbox.h>
|
||||
#include <qlineedit.h>
|
||||
#include <qpushbutton.h>
|
||||
|
||||
class FormUrlDialog : public QDialog {
|
||||
Q_OBJECT
|
||||
public:
|
||||
FormUrlDialog(FormUrl *form, QWidget *parent=0, const char *name=0,
|
||||
bool modal=false, WFlags f=0);
|
||||
~FormUrlDialog();
|
||||
|
||||
// widgets
|
||||
|
||||
QLabel *labelurl;
|
||||
QLabel *labelurlname;
|
||||
QLineEdit *url;
|
||||
QLineEdit *urlname;
|
||||
QCheckBox *htmlurl;
|
||||
QPushButton *buttonOk;
|
||||
QPushButton *buttonCancel;
|
||||
|
||||
protected:
|
||||
void closeEvent(QCloseEvent *e);
|
||||
|
||||
private:
|
||||
FormUrl *form_;
|
||||
|
||||
// layouts
|
||||
|
||||
QHBoxLayout *topLayout;
|
||||
QVBoxLayout *layout;
|
||||
QHBoxLayout *urlLayout;
|
||||
QBoxLayout *urlnameLayout;
|
||||
QBoxLayout *htmlurlLayout;
|
||||
QHBoxLayout *buttonLayout;
|
||||
|
||||
private slots:
|
||||
/// gate to FormUrl::apply
|
||||
void apply_gate(void) {
|
||||
form_->apply();
|
||||
form_->close();
|
||||
hide();
|
||||
}
|
||||
|
||||
/// gate to FormUrl::close
|
||||
void close_gate(void) {
|
||||
form_->close();
|
||||
hide();
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
@ -1,29 +1,41 @@
|
||||
# KDE Config File
|
||||
[Workspace_1]
|
||||
openfiles=Untitled.h,Untitled.cpp,
|
||||
show_outputview=true
|
||||
show_treeview=true
|
||||
header_file=Untitled.h
|
||||
cpp_file=Untitled.cpp
|
||||
browser_file=file:/usr/doc/qt1x-devel-1.45/qimageio.html
|
||||
[formcopyright.C]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=SOURCE
|
||||
[Workspace_1]
|
||||
openfiles=Untitled.h,Untitled.cpp,/nfs/sinco/source/lyx/rae/src/frontends/kde/formcopyrightdialog.h,
|
||||
show_outputview=true
|
||||
show_treeview=true
|
||||
header_file=/nfs/sinco/source/lyx/rae/src/frontends/kde/formcopyrightdialog.h
|
||||
cpp_file=Untitled.cpp
|
||||
browser_file=file:/usr/doc/qt1x-devel-1.44/qdialog.html
|
||||
[Config for BinMakefileAm]
|
||||
ldflags=
|
||||
cxxflags=-O0 -g3 -Wall
|
||||
bin_program=lyxgui
|
||||
cxxflags=-O0 -g3 -Wall
|
||||
[formcopyright.h]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=HEADER
|
||||
[dlg/form_document.kdevdlg]
|
||||
widget_files=
|
||||
data_file=
|
||||
install_location=
|
||||
classname=
|
||||
baseclass=
|
||||
header_file=
|
||||
dist=true
|
||||
cpp_file=
|
||||
install=false
|
||||
is_toplevel_dialog=true
|
||||
type=KDEV_DIALOG
|
||||
[dlg/Makefile.am]
|
||||
files=dlg/formcopyrightdialog.kdevdlg,
|
||||
type=static_library
|
||||
files=dlg/formcopyrightdialog.kdevdlg,dlg/form_document.kdevdlg,
|
||||
sub_dirs=
|
||||
type=static_library
|
||||
[LFV Groups]
|
||||
Dialogs=*.kdevdlg,
|
||||
GNU=
|
||||
@ -59,13 +71,13 @@ type=KDEV_DIALOG
|
||||
[General]
|
||||
makefiles=Makefile.am,dlg/Makefile.am,
|
||||
version_control=None
|
||||
author=Jürgen Vigna
|
||||
project_type=normal_empty
|
||||
author=Jürgen Vigna
|
||||
sub_dir=dlg/
|
||||
lfv_open_groups=Headers,Sources,Dialogs,
|
||||
workspace=1
|
||||
version=0.1
|
||||
project_name=LyxGUI
|
||||
version=0.1
|
||||
email=jug@sad.it
|
||||
kdevprj_version=1.0beta2
|
||||
[formcopyrightdialog.C]
|
||||
@ -78,24 +90,24 @@ install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=SOURCE
|
||||
[Makefile.am]
|
||||
files=lyxgui.kdevprj,FormCopyright.h,FormCopyright.C,formcopyrightdialog.h,formcopyrightdialog.C,formcopyrightdialogdata.C,
|
||||
sub_dirs=dlg,
|
||||
type=prog_main
|
||||
sub_dirs=dlg<,
|
||||
type=normal
|
||||
[lyxgui.kdevprj]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=DATA
|
||||
[formcopyrightdialogdata.C]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=SOURCE
|
||||
[Makefile.am]
|
||||
files=lyxgui.kdevprj,FormCopyright.h,FormCopyright.C,formcopyrightdialog.h,formcopyrightdialog.C,formcopyrightdialogdata.C,
|
||||
type=normal
|
||||
sub_dirs=dlg<,dlg,
|
||||
type=prog_main
|
||||
sub_dirs=dlg,
|
||||
[formcopyrightdialog.h]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=HEADER
|
||||
[formcopyrightdialogdata.C]
|
||||
install_location=
|
||||
dist=true
|
||||
install=false
|
||||
type=SOURCE
|
||||
|
43
src/frontends/xforms/GUIRunTime_pimpl.C
Normal file
43
src/frontends/xforms/GUIRunTime_pimpl.C
Normal file
@ -0,0 +1,43 @@
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright (C) 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
*======================================================*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#include FORMS_H_LOCATION
|
||||
#include "GUIRunTime_pimpl.h"
|
||||
#include "debug.h"
|
||||
|
||||
GUIRunTime::Pimpl::Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
GUIRunTime::Pimpl::~Pimpl()
|
||||
{
|
||||
}
|
||||
|
||||
void GUIRunTime::Pimpl::processEvents()
|
||||
{
|
||||
// this is disabled for now as we still need this ALWAYS in lyx_gui
|
||||
// and if we enable this here we would do it 2 times well why not it
|
||||
// doesn't really matter, does it? (Jug)
|
||||
#if 1
|
||||
XEvent ev;
|
||||
|
||||
if (fl_check_forms() == FL_EVENT) {
|
||||
lyxerr << "LyX: This shouldn't happen..." << endl;
|
||||
fl_XNextEvent(&ev);
|
||||
}
|
||||
#endif
|
||||
}
|
36
src/frontends/xforms/GUIRunTime_pimpl.h
Normal file
36
src/frontends/xforms/GUIRunTime_pimpl.h
Normal file
@ -0,0 +1,36 @@
|
||||
// -*- C++ -*-
|
||||
/* This file is part of
|
||||
* ======================================================
|
||||
*
|
||||
* LyX, The Document Processor
|
||||
*
|
||||
* Copyright 2000 The LyX Team.
|
||||
*
|
||||
* @author Jürgen Vigna
|
||||
*
|
||||
* ====================================================== */
|
||||
|
||||
#ifndef GUIRUNTIME_PIMPL_H
|
||||
#define GUIRUNTIME_PIMPL_H
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma interface
|
||||
#endif
|
||||
|
||||
#include "frontends/GUIRunTime.h"
|
||||
|
||||
/*
|
||||
* The GUI interface for runtime GUI stuff.
|
||||
*/
|
||||
struct GUIRunTime::Pimpl {
|
||||
public:
|
||||
///
|
||||
Pimpl();
|
||||
///
|
||||
~Pimpl();
|
||||
///
|
||||
void processEvents();
|
||||
|
||||
private:
|
||||
};
|
||||
#endif
|
@ -13,6 +13,8 @@ ETAGS_ARGS = --lang=c++
|
||||
libxforms_la_SOURCES = \
|
||||
ButtonController.h \
|
||||
Dialogs.C \
|
||||
GUIRunTime_pimpl.C \
|
||||
GUIRunTime_pimpl.h \
|
||||
FormCitation.C \
|
||||
FormCitation.h \
|
||||
form_citation.C \
|
||||
|
@ -15,14 +15,6 @@
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#ifdef KDEGUI
|
||||
# include <kapp.h>
|
||||
#endif
|
||||
|
||||
#ifdef GTKGUI
|
||||
# include <gnome--/main.h>
|
||||
#endif
|
||||
|
||||
#include <fcntl.h>
|
||||
#include "lyx_gui.h"
|
||||
#include FORMS_H_LOCATION
|
||||
@ -47,6 +39,7 @@
|
||||
#include "bufferlist.h"
|
||||
#include "language.h"
|
||||
#include "ColorHandler.h"
|
||||
#include "frontends/GUIRunTime.h"
|
||||
|
||||
using std::endl;
|
||||
|
||||
@ -567,17 +560,15 @@ void LyXGUI::runTime()
|
||||
if (!gui)
|
||||
return;
|
||||
|
||||
GUIRunTime grt;
|
||||
|
||||
// XForms specific
|
||||
XEvent ev;
|
||||
|
||||
while (!finished) {
|
||||
#ifdef KDEGUI
|
||||
kapp->processEvents();
|
||||
#endif
|
||||
#ifdef GTKGUI
|
||||
while(Gnome::Main::instance()->events_pending()) Gnome::Main::instance()->iteration(FALSE);
|
||||
#endif
|
||||
|
||||
grt.processEvents();
|
||||
// for now we have to leave this here then if the GUII is
|
||||
// completed this obviously has to be removed! (Jug)
|
||||
if (fl_check_forms() == FL_EVENT) {
|
||||
lyxerr << "LyX: This shouldn't happen..." << endl;
|
||||
fl_XNextEvent(&ev);
|
||||
|
Loading…
Reference in New Issue
Block a user