Commit Graph

8269 Commits

Author SHA1 Message Date
Abdelrazak Younes
205096733a This commit introduces the FontLoader interface class. In the future, I intend to extend it with a proper encapsulation of font metrics.
* frontends/FontLoader.h: new interface class.
* frontends/Application.h: new FontLoader() pure virtual method
* frontends/lyx_gui: update_fonts() and font_available() methods deleted

* [qt3/qt4/gtk]/GuiApplication: implement the new interface

* qt4/GuiFontLoader:
  - renamed from FontLoader
  - now derives from FontLoader
  - now in the lyx::frontend namespace

* qt3/qfont_loader
  - now derives from FontLoader

* gtk/xftFontLoader
  - now derives from FontLoader



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15220 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 16:17:32 +00:00
Abdelrazak Younes
f78e126d1e APPLE compilation fix.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15218 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 15:51:16 +00:00
Jürgen Spitzmüller
172ab6c70f Fix the fix for bug 2869.
* src/insets/insetvspace.C (doDispatch): open dialog on 
	mouse release (not press).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15216 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 14:50:41 +00:00
Abdelrazak Younes
1b8c2a95df use theApp directly for default fonts.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15214 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 14:21:15 +00:00
Abdelrazak Younes
f1d2dfadbc Put back doxygen comments deleted from lyx_gui.h.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15212 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 13:59:01 +00:00
Abdelrazak Younes
85d2e4b917 * lyx_gui: create_view(), start() and exit() functions deleted.
* lyx_main.C and lyx_cb.C: use Application methods directly instead of the above functions.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15211 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 13:38:28 +00:00
Enrico Forestieri
69d72462b6 Avoid compile errors due to the min/max macros on mingw, too
* src/support/fontutils.C:
	Undefine the min and max macros if they are defined


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15210 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 12:37:18 +00:00
Abdelrazak Younes
046c9bb9e3 transfer lyx_gui::exit() to frontends/lyx_gui.C
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15209 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 11:42:33 +00:00
Abdelrazak Younes
63ad5449fb This commit creates a new "frontends/lyx_gui.C" that contains all functions that are not frontend dependent any more. It also creates 3 new pure virtual methods in Application:
virtual std::string const romanFontName() = 0;
virtual std::string const sansFontName() = 0;
virtual std::string const typewriterFontName() = 0;

My goal is to transfer all of "frontends/*/lyx_gui.C" to "frontends/lyx_gui.C". When this is done, "frontends/lyx_gui.C" can go altogether as its functions will then be replaced with direct calls to theApp->XXX().

* frontends/lyx_gui.C: new file with code transfered from [qt3,qt4,gtk]/lyx_gui.C

* frontends/Application: 3 new font related pure virtual methods

* [qt3,qt4,gtk]/GuiApplication: implement the above method with code transfered from lyx_gui.C


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15208 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 10:34:10 +00:00
Jürgen Spitzmüller
db9235f095 Fix bug 2869.
* src/insets/insetvspace.C (doDispatch): set cursor properly on mouse 
	(button 3) press.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15207 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 10:08:15 +00:00
Abdelrazak Younes
d1e7c7e0ab Integrate Application_pimpl into Application.C.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15206 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 08:43:32 +00:00
Georg Baum
2c72e0ecaa Fix bug 2868
* src/insets/insetgraphics.C
	(findTargetFormat): return pdf for vector graphics

	* src/format.h
	(Flags): new enum describing format flags
	(flags_): new member variable for format flags
	(vectorFormat): new, tell whether a format can contain vector graphics

	* src/format.C: adjust to flags changes

	* src/frontends/qt[34]/QPrefsDialog.C
	(QPrefsDialog::QPrefsDialog): handle new vector flag
	(QPrefsDialog::switch_format): ditto
	(QPrefsDialog::updateFormatsButtons): ditto
	(QPrefsDialog::new_format): ditto
	(QPrefsDialog::modify_format): ditto

	* src/frontends/qt3/ui/QPrefFileformatsModule.ui
	* src/frontends/qt4/ui/QPrefFileformatsUi.ui
	(vectorCB): new checkbox for vector flag

	* src/lyxrc.C
	(LyXRC::read): read vector flag
	(LyXRC::write): write vector flag

	* lib/doc/Customization.lyx: document format flags

	* lib/configure.py
	(checkFormatEntries): Add vector flag to some formats


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15205 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 08:34:59 +00:00
Georg Baum
8fb869e7c6 Missing bits of the std::string -> hullType change of InsetMathHull::type_.
Now we write again \begin{align} instead of \begin{4} to .lyx and .tex.
	* src/mathed/InsetMathHull.C
	(InsetMathHull::header_write): write type name, not type_.
	Use switch instead of if for better readability.
	(InsetMathHull::footer_write): ditto
	(InsetMathHull::mutate): write type name, not type_
	(InsetMathHull::normalize): ditto
	(InsetMathHull::infoize): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15204 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 07:56:27 +00:00
Enrico Forestieri
42b65db612 Avoid a compilation error on cygwin
* src/support/fontutils.C:
	Undefine the min and max macros after inclusion of windows.h on cygwin.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15203 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-03 00:58:53 +00:00
Georg Baum
8a9d0934e9 Parse optional arguments of aligned, gathered and alignedat
* src/mathed/InsetMathSplit.[Ch]
	(InsetMathSplit): Add valignment argument to constructor

	* src/mathed/InsetMathSplit.C
	(InsetMathSplit::write): write vertical alignment if needed

	* src/mathed/MathParser.C
	(Parser::parse1): parse optional arguments of aligned, gathered and
	alignedat


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15202 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-02 20:01:30 +00:00
Enrico Forestieri
5070d2f660 Fix build on cygwin when using --without-x
* src/frontends/qt4/GuiView.C
	(setGeometry): replace test for Q_OS_WIN32 with Q_WS_WIN

	* src/support/fontutils.C:
	If X_DISPLAY_MISSING is defined, compile the code for Win32
	on cygwin, too.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15201 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-02 18:21:48 +00:00
Abdelrazak Younes
481e6a3ac7 A fix from Ozgur Ugras BARAN:
A trivial (looking) patch to correct inset behavior, which is broken
with revision 15068. Without this patch, it is not possible to modify
an existing inset. All modifications processed as new index. (see
lyxfunc.C:1420)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15199 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-02 15:40:39 +00:00
Abdelrazak Younes
6a947f349b This commit moves system font initialization and restoration to new support/fontutils.[Ch].
These font related functions were identical for qt3 and qt4. They are not Qt dependent at all and could also apply to an eventual Win32 or MacOSX gtk port.

Jen-Marc says: It would be nice to convince fontconfig to do the same for linux.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15196 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-02 10:48:03 +00:00
Georg Baum
deef368edc Fix bug 2789 (as discussed)
* src/mathed/InsetMathHull.C
	(InsetMathHull::doDispatch): move code for ref insert to InsetMathNest 
	(InsetMathHull::getStatus): move code for ref insert to InsetMathNest

	* src/mathed/InsetMathNest.C
	(InsetMathNest::doDispatch): move code from InsetMathHull here
	(InsetMathNest::getStatus): move code from InsetMathHull here


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15189 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-30 17:17:31 +00:00
Georg Baum
6eab6ea732 remove unneeded include
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15188 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-30 10:24:05 +00:00
Georg Baum
e9f25b4861 Make it compile again: Add some includes to fix signals name clash
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15187 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-30 08:58:17 +00:00
Abdelrazak Younes
9a2427e0b8 remove a FIXME, sorry for the multiple commits...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15186 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 23:22:53 +00:00
Abdelrazak Younes
315d394338 Some cleanup
* Application.h: pimpl_ is now private

* GuiApplication.C: headers cleanup.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15185 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 23:21:03 +00:00
Abdelrazak Younes
0548914973 some qt3 and gtk compilation fixes (hopefully)...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15184 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 23:15:36 +00:00
Abdelrazak Younes
3a1f656e4e * Application: new createView() method
* gtk/qt3/qt4/GuiApplication: createView() method deleted

* LyXView:
 - init(): is now a pure virtual method. autoSave code transferred to constructor and updates to the frontends.
 - setGeometry(): new pure virtual method

* gtk/GView, qt3/QtView, qt4/GuiView: adapted to above change
 - setGeometry(): code transfered from GuiApplication

* lyx_main.C: call LyX::ref().addLyXView() in there instead of in Application::createView()


* 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15183 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 23:10:17 +00:00
Abdelrazak Younes
ca5411f913 This commit introduces Application_pimpl and cleanup the header includes of the affected .C files.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15182 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 22:06:28 +00:00
Abdelrazak Younes
34694773c6 This commit splits the add() method in two methods add() and
addWithStatus(). It also replaces LyXView uses with BufferView as none of the LyXView feature were used.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15181 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-29 21:40:56 +00:00
Enrico Forestieri
12a6d46370 Small fixes for STLPort compliance
* src/cursor.C: add using std::for_each;

	* src/graphics/GraphicsTypes.h: add #include <string>

	* src/graph.C: add using std::fill;

	* src/frontends/controllers/helper_funcs.h: add #include <algorithm>

	* src/bufferview_funcs.C: add using std::find;

	* src/lyx_main.C: add using std::for_each;

	* configure.ac: don't use boost format on cygwin


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15176 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-28 00:42:47 +00:00
Georg Baum
70d57a2300 Implement copying of rows and columns in tables
* src/insets/insettabular.C
	(InsetTabular::getStatus): enable COPY_ROW and COPY_COLUMN features
	(InsetTabular::tabularFeatures): handle COPY_ROW and COPY_COLUMN

	* src/tabular.h
	(TabularFeature): add COPY_ROW and COPY_COLUMN

	* src/tabular.[Ch]
	(LyXTabular::copyRow): new method, copy a row
	(LyXTabular::copyColumn): new method, copy a column


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15173 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-27 16:28:09 +00:00
Georg Baum
864515f3a3 avoid comparing the addresses of dereferenced 0 pointers
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15172 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-27 16:10:47 +00:00
Jean-Marc Lasgouttes
3bbc232e67 compilation fix: do not forget lyx_gui.h
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15164 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-27 13:37:50 +00:00
Abdelrazak Younes
1396c73262 replace global variable bufferlist with Application class member access.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15161 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-27 10:24:13 +00:00
Abdelrazak Younes
b3cacd0238 delete unneeded lyx_gui.h declaration.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15160 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-27 08:33:37 +00:00
Abdelrazak Younes
0da12b129a delete unneeded BufferView.h declaration.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15159 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 21:11:22 +00:00
Abdelrazak Younes
a9ddcfc77c 2 style and 1 compilation fixes.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15156 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 12:46:27 +00:00
Abdelrazak Younes
c2cc205852 qt3 and gtk support for revision: 15153
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15155 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 11:55:46 +00:00
Abdelrazak Younes
b171e5f150 Free BufferView from LyXView!
* BufferView
  - layoutChanged: new boost signal.
  - LyXView owner(), owner_: deleted

* text3.C
  - emit BufferView::layoutChanged instead of calling LyXView::setLayout directly
  - LFUN_MOUSE_RELEASE: delete LyXView updateMenubar() and updateToolbars() direct calls.
    The update is of both bars is done in WorkArea::dispatch().

* WorkArea.C
  - dispatch(): add LyXView updateMenubar() call.

* LyXView
  - connects to BufferView::layoutChanged directly to Toolbars::setLayout()
  - setLayout(): deleted.

* qt4/GuiImplementation: modify BufferView construction (without LyXView).

All other files: cleanup header declaration of LyXView.h


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15153 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 10:06:46 +00:00
Abdelrazak Younes
1ead706c96 * emit buffer::resetAutosaveTimers instead of calling LyXView::resetAutosaveTimer() directly
* replace bv->owner()->buffer() with bv->buffer()


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15152 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 09:59:03 +00:00
Abdelrazak Younes
10d5ea0d8a replace colorcache global variable with GuiApplication::colorCache().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15151 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-26 09:57:47 +00:00
Georg Baum
e1acd31e28 Disable concept checks in the same way as in other gtk files since they
don't work with libsigc++ 2.0.6.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15146 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-25 16:58:40 +00:00
Georg Baum
063994371e make it compile again
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15132 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 21:00:42 +00:00
Georg Baum
ebaaff58fa make it compile again
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15131 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 20:48:42 +00:00
Georg Baum
884022b16a remove unused stuff
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15130 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 19:17:29 +00:00
Georg Baum
c2ffa71fa7 compile fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15129 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 18:45:22 +00:00
Georg Baum
577f9fca6f fix eol-style
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15127 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 17:50:33 +00:00
Georg Baum
48bd3057a8 Add virtual destructor
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15126 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 17:47:15 +00:00
Abdelrazak Younes
12a82dd4f2 This commit replaces BufferView->LyXView->Gui->[selection,clipboard] with theApp->[selection,clipboard]
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15125 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 15:02:41 +00:00
Abdelrazak Younes
480b4f4fdc This commit replaces BufferView->LyXView->getLyXFunc() with theApp->lyxFunc() and BufferView->LyXView->dispatch() with theApp->lyxFunc().dispatch().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15121 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 14:26:06 +00:00
Abdelrazak Younes
6104eebe0d replace lyxserver and lyxsocket with theApp->server() and theApp->socket() equivalent methods.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15119 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 12:34:13 +00:00
Georg Baum
112f533459 Fix a crash that occured on exit if the clipboard was not empty
(only on windows).
	* src/frontends/Dialogs.C
	(Dialogs::hide): Don't send the signal if we are quitting


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15116 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 10:03:00 +00:00
Abdelrazak Younes
3f0fadc48a This commit introduces frontends/Application.[Ch] and makes qt4/GuiApplication (renamed from qt4/Application) derive from it. Most of the code in qt4/lyx_gui.C has been transferred either to Application or to qt4/GuiApplication. Application handles unique instances of LyXFunc, LyXServer and LyXServerSocket.
Most of qt3 and gtk should stay compilable except for LyXView.h because the LyXFunc instance has been transferred to Application.

* frontends/Application: new class aimed to be the one unique interface between the frontend and the kernel. Contains one global pointer to the unique instanciation theApp.

* frontends/qt4/GuiApplication: renamed from qt4/Application, the qt4 specialisation of the Application class.  Contains one global pointer to the unique instanciation guiApp (equal to theApp but pointing to a GuiApplication instead).

* frontends/qt4/lyx_gui.C: most of the code has been moved to Application and GuiApplication

All other file: adapted to new API.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15114 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-22 09:47:39 +00:00
Jean-Marc Lasgouttes
2e1ba6d837 * lyxfunc.C (getStatus): fix handling of LFUN_RUNCHKTEX (bug 2831)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15101 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-21 10:43:49 +00:00
Jean-Marc Lasgouttes
f2dcbec8cb * lyxfunc.C (getStatus): fix handling of LFUN_RUNCHKTEX (bug 2831)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15096 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-21 09:46:52 +00:00
Jean-Marc Lasgouttes
9917aca0b7 * insettabular.C (cutSelection): reset cursor when it is invalid.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15088 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-20 12:16:26 +00:00
Jürgen Spitzmüller
e81cc81232 * src/CutAndPaste.C (pasteSelectionHelper):
remove accidentally committed, obsolete FIXME comment.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15085 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-20 06:55:07 +00:00
Georg Baum
e06cb910aa remove unused function _(docstring const &)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15069 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-19 16:41:18 +00:00
Abdelrazak Younes
311ac9b192 This is the continuation of my BufferView/LyXView cleanup. This commit replaces BufferView->LyXView->getDialogs().[show(), update()] with BufferView signal emissions.
The associated WorkArea is then responsible to connect these signals to its LyXView parent.

* BufferView:
  - showDialog, showDialogWithData, showInsetDialog: new boost signals

* LyXView:
  - connectBufferView(), disconnectBufferView(): new method in charge of the connection/disconnection of the above signal to associate private methods (showDialog(), etc).

* WorkArea
  - setBufferView(): will connect/disconnect the BufferView to its LyXView parent.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15068 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-19 13:36:20 +00:00
Jürgen Spitzmüller
023fb5433c Cleanup fix for bug 2382:
* src/CutAndPaste.C (pasteSelectionHelper): pass Cursor 
	as argument, remove cursor-dependent arguments, 	
	implement method to reset layout in insets which
	forceParagraphsToDefault.

	* src/CutAndPaste.C (pasteParagraphList): adapt call of 
	pasteSelectionHelper.

	* insets/insetbox.C (doDispatch):
	* insets/insetert.C (doDispatch):
	* insets/insetcharstyle.C (doDispatch):
	* insettext.[Ch] (forceParagraphsToDefault):
		remove ad-hoc-Code to 
		reset paragraph layout. 
		This is now done generally in CutAndPaste.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15062 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-19 09:39:17 +00:00
Lars Gullik Bjønnes
dfd9c61b31 propdel svn:executable
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15056 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-19 07:09:36 +00:00
Lars Gullik Bjønnes
c8e78b04ba Set caption programmatically instead of through the ui file. Opens up for disregarding caption in l10n handling of ui files.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15043 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-18 16:55:54 +00:00
Lars Gullik Bjønnes
8ebf862adb Fix breakage caused by bad commits.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15033 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 14:58:42 +00:00
Abdelrazak Younes
87adf196c1 Make ensureBufferClean a private member of LyXFunc. This avoids the bv->owner()->dispatch() redirection.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15032 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:51:59 +00:00
Abdelrazak Younes
2b0a849d36 use owner instead of owner->view()->owner
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15031 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:20:45 +00:00
Abdelrazak Younes
1a786c8e17 * Transfer Intl member from LyXView to BufferView.
* delete unused offset_ref() method.




git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15030 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:03:00 +00:00
André Pönitz
3537aa7448 cleanup after svn hang-up, #undef CursorShape. Should be compilable ganin now.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15029 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 10:00:15 +00:00
Abdelrazak Younes
14dff4fcb0 compilation fixes
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15028 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 09:55:13 +00:00
André Pönitz
e89625ef28 rename mathed/math_xinset into mathed/InsetMathX
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15026 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 09:14:18 +00:00
Abdelrazak Younes
397605290d delete unsetXSel() method
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15025 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 08:48:06 +00:00
Abdelrazak Younes
574e4444a8 Move X11 specific selection code from BufferView to the frontends.
* BufferView:
 - selectionRequested(): renamed to requestSelection() and cleaned up.
 - selectionLost(): renamed to clearSelection()

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15024 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-17 08:35:12 +00:00
André Pönitz
2805c29734 rename Math*Inset into InsetMath*
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15023 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 18:11:38 +00:00
Abdelrazak Younes
c9b19706d1 Kernel::isBufferAvailable(): replace the implicit pointer cast.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15020 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 14:27:27 +00:00
Lars Gullik Bjønnes
d8f91273d3 Fix trying to translate docstring/non-ascii text.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15019 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 14:03:30 +00:00
Abdelrazak Younes
1a0f5eaf8d deledelete BufferView::available() method because buffer serves the same purpose.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15018 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 14:00:13 +00:00
Abdelrazak Younes
972e1eec7c delete BufferView::text() method and add two FIXME in text.C
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15017 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 13:34:09 +00:00
Abdelrazak Younes
bcb71b1fbe Merge BufferView and BufferView_pimpl
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15013 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-16 10:08:51 +00:00
Georg Baum
69c447720a Add phantom icons from Uwe and me (last part of bug 1473)
* src/frontends/controllers/ControlMath.C
	(latex_misc): Add phnatom, vphantom and hphantom

	* lib/images/math/hphantom.xpm: new
	* lib/images/math/phantom.xpm: new
	* lib/images/math/vphantom.xpm: new

	* lib/Makefile.am: add new files
	* development/scons/scons_manifest.py: ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15009 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-15 10:58:58 +00:00
Jean-Marc Lasgouttes
759849aa42 * text.C (setCursorFromCoordinates):
* text2.C (setCursorIntern): add an assertion.

	* BufferView_pimpl.C (scrollDocView): reset cursor before setting
	it from coordinates (bug 2830).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15004 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-15 09:51:41 +00:00
Jean-Marc Lasgouttes
77fd733217 link lyxclient against iconv
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15003 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-15 09:39:10 +00:00
Jean-Marc Lasgouttes
349aac558e * paragraph_funcs.C (breakParagraph): make sure to respect nesting
when depth > 0 (bug 2445)/



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15002 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-15 09:38:40 +00:00
Jürgen Spitzmüller
a7ed5b9486 * src/text3.C (doInsertInset): reset first paragraph to default after selected content has been pasted (bug 2802)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14993 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-14 13:44:53 +00:00
Georg Baum
9080c44458 Use wchar_t as lyx::char_type if it is 32 bit wide.
No scons and cmake support! scons and cmake need to find out the size of
wchar_t and define this macro in config.h (example for 32bit wchar_t):

* The size of a `wchar_t', as computed by sizeof. */
#define SIZEOF_WCHAR_T 4

	* configure.ac: Test size of wchar_t

	* src/support/types.h: don't include docstring.h anymore.
	Use wchar_t as lyx::char_type if it is 32 bit wide.

	* src/support/docstring.h: Use lyx::char_type for defining docstring

	* src/metricsinfo.h: include support/docstring.h instead of
	support/types.h
	* src/lyxlex.h: ditto
	* src/frontends/font_metrics.h: ditto
	* src/frontends/qt4/qt_helpers.h: ditto
	* src/frontends/Painter.h: ditto
	* src/errorlist.h: ditto
	* src/support/lstrings.h: ditto
	* src/lyxfunc.h: ditto
	* src/LaTeX.h: ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14991 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-13 21:13:49 +00:00
Georg Baum
59fdb31af3 s/boost::uint32_t/lyx::char_type/g except in the definition of lyx::docstring
and lyx::char_type


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14990 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-13 17:11:39 +00:00
Georg Baum
a82ca1eed1 * src/frontends/qt4/QLToolbar.C
(QLToolbar::QLToolbar): Fix initialization order


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14989 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-13 17:04:42 +00:00
Georg Baum
37f22e93a2 * src/frontends/qt3/QLPopupMenu.C
(QLPopupMenu::populate): Don't append a lyx::char_type to a qstring


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14988 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-13 16:36:56 +00:00
Georg Baum
61102f1028 Compile fix for the case when USE_BOOST_FORMAT is 0
* src/support/lstrings.C
	(bformat): Add missing lyx::from_ascii()

	* src/support/convert.C
	(docstring convert<docstring>(unsigned int)): Add specialization
	(docstring convert<docstring>(long)): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14983 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-13 11:18:13 +00:00
Enrico Forestieri
179ff08011 Avoid a name clash with boost 1.34
* src/lyx_cb.C (reconfigure):
	* src/buffer.C (runChktex):
	* src/lyxfunc.C (dispatch):
	* src/vc-backend.C (doVCCommand):
	* src/lyx_main.C (reconfigureUserLyXDir):
	Explicitly specify lyx::support::Path.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14982 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-12 17:41:50 +00:00
Enrico Forestieri
f66b23b4df Fix combo box items in the delimiter GUI
* src/frontends/qt4/QDelimiterDialog.C
	(QDelimiterDialog::QDelimiterDialog): add missing "Variable size" item.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14981 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-12 01:17:03 +00:00
Georg Baum
d17a57a6f3 Fix converters in our scripts directory
* src/graphics/GraphicsConverter.C
	(build_script): quote filenames in the python script properly
	(build_script):
	(build_script):

	* src/support/filetools.[Ch]
	(quoteName): Add quote_style argument and quoting of python filenames
	(libScriptSearch): Add quote_style argument

	* src/support/filetools.C
	(quote_style): New enum to specify the quoting style


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14978 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 16:07:49 +00:00
Georg Baum
e45d0fb4e4 another compile fix I forgot
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14977 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 13:18:41 +00:00
José Matox
89a92e955d Fix from George to deal with the --disable-nls case
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14976 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 11:58:47 +00:00
Georg Baum
68eab2b645 compile fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14975 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 11:02:36 +00:00
Jean-Marc Lasgouttes
3253193b63 * src/client/debug.C (showLevel):
* src/ispell.C (ISpell,check): compilation fix



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14974 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 10:27:48 +00:00
Georg Baum
fc83b49fd4 make it compile again
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14973 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 10:07:39 +00:00
Abdelrazak Younes
a6444784dc A bunch of conversion to docstring.
- bformat(): contributed by Georg Beaum
- Alert::XXX
- error(): in SpellBase, ispell, psell, aspell, buffer, etc.
- message(), message signal
- displayMessage(), setMessage,
- ErrorItems
- prettyName()
- makeDisplayPath()

and maybe some more...


- etc... 

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14970 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 08:54:10 +00:00
Georg Baum
189d298d96 Add operator+ for ASCII characters and ASCII C strings
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14969 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-11 07:13:56 +00:00
Lars Gullik Bjønnes
bb61b2655f More unicode work. Fixup some usages.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14968 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 18:34:24 +00:00
Lars Gullik Bjønnes
2a06b31354 Some further work and simplification. Now the conversion engine is only restarted on error.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14967 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 16:59:36 +00:00
Lars Gullik Bjønnes
8fd2299744 Cleanup and speedup some of the conversion functions a bit.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14966 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 11:39:57 +00:00
Abdelrazak Younes
4b7fe14620 Revision 14964: forgot this...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14965 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 11:09:25 +00:00
Abdelrazak Younes
c9c47c6464 * LyXView.h:
- makeToolbar(): new pure virtual method

* qt4/GuiView.h:
  - makeToolbar(): new method transferred from QLToolbar

* qt4/QLToolbar: derive from QToolBar instead of owning a QToolBar member.

* Toolbars.h: remove make_toolbar() prototype (use LyXView::makeToolbar instead).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14964 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 11:03:21 +00:00
Abdelrazak Younes
42a7588f32 winwin32 compilation fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14963 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 10:53:23 +00:00
Abdelrazak Younes
cfb1d179e6 win32 compilation fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14962 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 10:32:41 +00:00
Georg Baum
a91f077dbd remove unused "using" directives
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14960 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 09:54:51 +00:00
Georg Baum
170adea390 Don't lie in debug messages: s/GuiClipboard/GuiSelection/
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14959 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 09:42:02 +00:00
Georg Baum
3000b1baff Fix return value of InsetInclude::plaintext
* src/insets/insetinclude.C
	(InsetInclude::plaintext): Add line counting code


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14958 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 09:28:00 +00:00
Georg Baum
9b5a63aaaf Fix return value of InsetText::plaintext
* src/insets/insetnote.C
	(InsetNote::plaintext): Move line counting code from here ...

	* src/insets/insettext.C
	(InsetText::plaintext): ... here.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14957 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 08:41:39 +00:00
Georg Baum
d929950da4 compile fix: add missing lyx::to_utf8() around _()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14956 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-10 08:14:30 +00:00
Lars Gullik Bjønnes
0dc81f2463 Change MenuBackend and the other menuclasses to store a docstring. Do the required updates to lstrings/convert.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14955 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 22:27:22 +00:00
Lars Gullik Bjønnes
b5fccd53ac Add a virtual in the child as well.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14954 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 22:18:05 +00:00
Lars Gullik Bjønnes
edd81011ce Change editMessage to return a docstring, change functions to not use to_utf8.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14953 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 18:52:00 +00:00
Lars Gullik Bjønnes
43b77ba2d7 Change _() to return a docstring. Fixup callers with the help of lyx::to_utf8.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14952 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 15:27:44 +00:00
Lars Gullik Bjønnes
5aa348d969 Make the l10n machinery work with ucs4. Update (as wip) callers to do manual conversion and a FIXME comment. Lots of work to do.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14951 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-09 11:16:28 +00:00
Georg Baum
c20cf44f4e remove unused 'using lyx::support::quoteName;'
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14946 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 15:32:20 +00:00
Bo Peng
f478418d3f Minor os_cygwin.C change, from Enrico
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14945 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 15:07:22 +00:00
Bo Peng
31d4e8d00f Do not print locale warning under cygwin, from Enrico
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14942 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 14:43:50 +00:00
Jean-Marc Lasgouttes
fe8d08d72f Improve Inset dissolve capability (bug 2201).
* src/insets/insettabular.C (getStatus):
	* src/insets/insettext.C (doDispatch,getStatus): remove special code
	for LFUN_INSET_DISSOLVE.

	* src/text.C (dissolveInset): new method.
	(erase, backspace): use dissolveInset. 

	* src/text3.C (dispatch): use dissolveInset for LFUN_INSET_DISSOLVE.
	(getStatus): disable LFUN_INSET_DISSOLVE if the inset has more than one 	cell.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14940 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 14:08:26 +00:00
Jean-Marc Lasgouttes
45808381d0 Fix bug 2251 (from G Baum)
* src/mathed/math_hullinset.h (displayMargin): new static method.
	* src/mathed/math_hullinset.C (metrics): use displayMargin().

	* src/text2.C (cursorUp, cursorDown): use MathHullInset::displayMargin.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14939 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 13:52:41 +00:00
Jean-Marc Lasgouttes
1822466e57 * BufferView_pimpl.C (getCurrentChange): do not assume that
LyXText at cursor position is the same as LyXText at
	cursor.selBegin() position. Fixes a crash (bug 2600).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14936 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-08 12:17:45 +00:00
Georg Baum
c7be292968 s/errno.h/cerrno/
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14932 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-07 15:23:16 +00:00
Georg Baum
71577b7c31 Fix compile error
* src/support/fs_extras.C: include errno.h



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14931 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-07 13:08:33 +00:00
Georg Baum
3f0fc88ced Fix bug 2698 (new images from Uwe Stöhr)
* src/frontends/controllers/ControlMath.C
	(latex_misc): Add intop and ointop

	* lib/images/math/intop.xpm: New
	* lib/images/math/ointop.xpm: Ditto

	* lib/images/math/int.xpm: Add box to make the difference to intop clear
	* lib/images/math/oint.xpm: ditto

	* lib/Makefile.am: add new files


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14924 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-07 09:51:50 +00:00
Michael Schmitt
b8f28d4a58 add comments on the purpose and status of some LFUNs
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14921 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-06 18:34:57 +00:00
Michael Schmitt
a2f396827c remove LFUN_INSET_SCROLL and LFUN_DIALOG_SHOW_NEXT_INSET
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14920 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-06 18:20:35 +00:00
Peter Kümmel
dc5a9f7d2c update to boost 1.34 cvs
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14911 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-06 09:47:45 +00:00
Lars Gullik Bjønnes
d64a07a784 Update in-tree boost to latest from boost 1.34 cvs.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14895 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-05 07:18:36 +00:00
Georg Baum
15be4fb8ef Fix byte order problems
* src/support/unicode.C
	(bytes_to_ucs4): make it work on big endian machines
	(bytes_to_ucs2): make it work on little endian machines
	(ucs2_to_ucs4): ditto
	(utf8_to_ucs4): Invoke iconv with explicit BE suffix
	(ucs2_to_ucs4): ditto
	(ucs4_to_ucs2): ditto
	(ucs4_to_utf8): ditto

	* configure.ac: Check for byte order

	* development/scons/SConstruct: Ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14890 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-04 14:43:25 +00:00
Abdelrazak Younes
b05e4c7a82 Fixes a MSVC/Qt4 crash when closing the Document Settings dialog.
* Dialogs::disconnect(string const & name): check if the dialog is an inset before resetting open_insets_


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14889 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-04 09:48:51 +00:00
André Pönitz
3663e1161a use enums instead of strings to distinguish different types of math hull
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14882 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 16:14:51 +00:00
Abdelrazak Younes
a6e0f26fe2 * MSVC compilation fix: replace subst template with subst_char and sub_string
* add lowercase() and uppercase() functions for unicode char_type.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14881 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 14:09:24 +00:00
Jürgen Spitzmüller
bae41d8a3b fix getStatus of LFUN_DISSOLVE_INSET:
* src/text3.C (getStatus): 
	disable the lfun in MainText.
* src/insets/insettabular.C (getStatus):
	disable inset-dissolve completely.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14879 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 13:39:54 +00:00
Abdelrazak Younes
9e18b8e975 All methods: use char_type as argument instead of char.
isLetterChar(): verify also that this is a one-byte char (<256).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14877 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 12:12:53 +00:00
Abdelrazak Younes
35ec954df8 This fixes the crash when PageDown scrolling UserGuide.lyx
* MathMacroTemplate::prefix(): now return docstring.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14876 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 11:54:17 +00:00
Georg Baum
e33bac93cd Fix clipboard/selection encoding
* src/frontends/qt[34]/qt_helpers.[Ch]
	(toqstr): add variant for docstring
	(qstring_to_ucs4): Use docstring and port from qt4 to qt3

	* Many other files: Many std::string -> lyx::docstring conversions

	* src/support/lstrings.[Ch]
	(subst): Add variant for docstring and char_type
	(externalLineEnding): std::string -> lyx::docstring
	(internalLineEnding): std::string -> lyx::docstring


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14871 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-03 07:02:38 +00:00
Georg Baum
0542f28f04 forgot this
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14868 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-02 10:27:28 +00:00
Georg Baum
6afe0b915c Fix some conversion problems spotted by MSVC warnings
* src/insets/insetquotes.[Ch]
	(InsetQuotes::InsetQuotes): char -> lyx::char_type

	* src/support/lstrings.h
	(contains): new variant for docstrings

	* src/frontends/controllers/ControlSpellchecker.C
	(isLetter): Add missing conversion to utf8
	(nextWord): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14867 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-02 10:18:20 +00:00
Abdelrazak Younes
14c30e2b84 iconv_convert(): return empty vector in case of empty input
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14866 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-02 08:01:50 +00:00
Bo Peng
6d23395dc7 Improve Computer Algebra System, from Enrico Forestieri <forenr@tlc.unipr.it>
* src/mathed/math_symbolinset.C
	(void MathSymbolInset::maxima):
	       - newer maxima versions use inf instead of INF
	       - add support for greek pi

	(void MathSymbolInset::mathematica):
	       - add support for \cdot

	* src/mathed/math_stringinset.h
	       - account for the const version of asStringInset()

	* src/mathed/math_extern.C
	(bool extractScript):
	       - added bool superscript to formal parameters in order
	         to only extract superscripts

	(MathArray::iterator extractArgument):
	       - leave out delimiters and a possible superscript
	         for function arguments

	(bool isKnownFunction):
	(bool extractFunctionName):
	       - recognize standard and user defined function names

	(void splitScripts):
	       - correctly split scripts as expected by other functions

	(MathAtom replaceDelims):
	       - ranamed as replaceParenDelims

	(bool testOpenBracket):
	(bool testCloseBracket):
	       - test for "[" and "]", respectively

	(MathAtom replaceBracketDelims):
	       - replace something delimited by "[" and "]" with a
	         proper DelimInset

	(void extractDelims):
	       - create a DelimInset for "[" and "]" delimiters, too

	(void extractFunctions):
	       - improved recognition of function names

	(bool testTermDelimiter):
	       - test for '+' or '-' as term delimiters

	(MathArray::iterator extractTerm):
	       - extract a "term", i.e., something delimited by '+' or '-'

	(bool testDiffItem):
	       - improved recognition of a "differential fraction"

	(void extractDiff):
	       - call splitScripts() on numerator and denominator of a
	         differential fraction before analyzing them

	(void extractLims):
	       - improved recognition of a limit function

	(void extractStructure):
	       - reorganized order of searches

	(MathArray pipeThroughMaxima):
	       - newer versions of maxima use simpsum instead of SIMPSUM

	(string fromMathematicaName):
	       - translates from mathematica names

	(MathArray pipeThroughMathematica):
	       - calls mathematica and collects its output

	(MathArray pipeThroughExtern):
	       - add support for mathematica

	* src/mathed/math_numberinset.C
	* src/mathed/math_numberinset.h
	(void MathNumberInset::mathematica):
	       - add support for mathematica

	* src/mathed/math_matrixinset.C
	* src/mathed/math_matrixinset.h
	(void MathMatrixInset::mathematica):
	       - add support for mathematica

	* src/mathed/math_diffinset.C
	* src/mathed/math_diffinset.h
	(void MathDiffInset::maxima):
	       - add support for maxima

	(void MathDiffInset::mathematica):
	       - mathematica uses "D" and not "Dt" for normal derivatives

	* src/mathed/math_liminset.C
	* src/mathed/math_liminset.h
	(void MathLimInset::maxima):
	       - add support for maxima

	(void MathLimInset::mathematica):
	       - mathematica uses "Limit" and not "Lim" for limits

	* src/mathed/math_exfuncinset.C
	(string asMathematicaName):
	       - added some more function names


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14865 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-02 01:57:36 +00:00
Georg Baum
1fc0c01877 convert lfun arguments to docstring
* src/support/docstring.[Ch]
	(from_ascii): new conversion function
	(from_utf8): new conversion function
	(to_utf8): new conversion function
	(operator==) new, compare docstring and ASCII C string
	(operator!=) new, compare docstring and ASCII C string

	* src/support/Makefile.am: add new file docstring.C

	* development/scons/scons_manifest.py: ditto

	* src/funcrequest.[Ch]
	(argument): change name to argument_ and type to docstring,
	add an accessor
	(FuncRequest): Add two new constructors taking a docstring argument

	* all other files: adjust to the FuncRequest changes above


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14861 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-01 15:41:38 +00:00
Abdelrazak Younes
b486b53f8f Patch from Enrico:
Avoids the crash when quitting LyX on Cygwin/qt4


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14860 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-01 13:49:03 +00:00
Abdelrazak Younes
02f51e1820 Patch from Enrico:
In src/support/os_cygwin.C path styles are converted (when needed) from
one style to another. I discovered a couple of cases in which an
unnecessary conversion takes place.

The default output path style in external_path is windows because this
function is also used when adding fonts though a native Windows API call.
However, this call is not made in an X11 build, so it is not necessary
that the output path style is windows.

Log:
Small fixes for cygwin.

	* os_cygwin.C (is_windows_path): avoid unnecessary conversion
	when path is relative
	(convert_path_list): avoid unnecessary conversion when path
	list is empty
	(external_path): for an X11 build it is not necessary that
	the output path style is windows


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14859 a592a061-630c-0410-9148-cb99ea01b6c8
2006-09-01 13:37:52 +00:00
Lars Gullik Bjønnes
86b063d2da Use correct types for qstring, also to avoid 64<->32 bit issues.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14858 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-31 20:36:07 +00:00
Lars Gullik Bjønnes
810f6e499b Use exceptions to avoid more than one call to the filesystem.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14857 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-31 19:32:12 +00:00
Edwin Leuven
74344a8f4b further ui cleanup: correct tab order
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14856 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-31 13:46:28 +00:00
Edwin Leuven
27fa8c7d12 correct tab order + layout cleanup
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14855 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-31 13:07:05 +00:00
Abdelrazak Younes
d64b3a4a0a simple one line optimisation in iconv_convert().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14854 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-31 08:49:12 +00:00
Abdelrazak Younes
4d5767fd9c * qt_helpers.[Ch]: new conversion from/to ucs4 strings and chars to/from QChar and QString.
* qfont_metrics.C: make use of above methods instead of those in unicode.[Ch]

* QLPainter.C: ditto

* QLyXKeySym.C: ditto + simplification and a BOOST_ASSERT that verifies that the event is one char only.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14852 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-30 14:59:07 +00:00
Abdelrazak Younes
72a680e261 small cleanup: delete two unneeded lines of code.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14850 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-29 09:08:51 +00:00
Jürgen Spitzmüller
16b150e6bf * src/buffer.C (save):
catch exception thrown by boost::filesystem if copying to the 
	backup directory fails (fixes bug 2740: crash and dataloss if
	the backup dir was invalid or not writeable).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14849 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-29 08:38:00 +00:00
Georg Baum
0df0e32b22 fix dropping of UNC filenames on windows (from Enrico)
* src/frontends/qt4/GuiWorkArea.C
	(GuiWorkArea::dropEvent): Use toLocalFile instead of toString,
	because toString omits the first backslash of UNC paths.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14846 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-27 16:10:41 +00:00
Edwin Leuven
e28114779b minimal effort implementation of:
* float widget as a .ui file
* floatplacement.[Ch] -> FloatPlacement.[Ch] 



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14838 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-25 13:40:01 +00:00