Commit Graph

22 Commits

Author SHA1 Message Date
Abdelrazak Younes
bf61ecc2de Support code for advanced Toc management and bug correction.
* buffer.h:
  - structureChanged(): new boost signal. I intend to use that also when a text is changed in a section or caption item.

* buffer_funcs.C:
  - updateLabels(): emit Buffer::structureChanged() after TocBackend is updated.
  - checkBufferStructure(): new method for updating the TocBackend if needed.

* LyXView:
  - updateToc(): new slot for Buffer::structureChanged() signal.

* text.C:
  - call checkBufferStructure() whenever text is added or erased.

* TocBackend.[Ch]:
  - updateItem(): new method to update a specific item (called from checkBufferStructure()).



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17413 a592a061-630c-0410-9148-cb99ea01b6c8
2007-03-12 11:23:41 +00:00
Abdelrazak Younes
e68d69e473 Translate labels based on the paragraph language instead of the Buffer language.
* Buffer:
  - translateLabel(): deleted.

* Paragraph:
  - translateIfPossible(): new method.
  - expandLabel(): new method.

* buffer_funcs.[Ch]
  - expandLabel(): deleted.



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16694 a592a061-630c-0410-9148-cb99ea01b6c8
2007-01-15 16:58:14 +00:00
Georg Baum
ed99f752f9 more unicode filenames
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16133 a592a061-630c-0410-9148-cb99ea01b6c8
2006-12-02 16:07:15 +00:00
Georg Baum
2734cc1548 Extend the navigate menu to child docs
* src/buffer_funcs.h
	(updateLabels): Add bool childonly argument

	* src/insets/insetbase.h
	(addToToc): New virtual method

	* src/insets/insetinclude.[Ch]
	(addToToc): New virtual method
	(updateLabels): New method

	* src/TocBackend.h: reorganize classes so that we can forward
	declare TocList

	* src/insets/insetfloat.[Ch]
	* src/insets/insetwrap.[Ch]
	(addToToc): Adjust to type changes in TocBackend.h

	* src/frontends/qt4/TocModel.[Ch]: ditto

	* src/frontends/controllers/ControlToc.[Ch]: ditto

	* src/TocBackend.C: ditto
	(TocBackend::update) Remove test for float and wrap inset,
	call virtual method instead

	* src/BufferView.C
	(BufferView::dispatch): make LFUN_PARAGRAPH_GOTO work even if the
	target paragraph is in a different buffer

	* src/MenuBackend.C: Adjust to type changes in TocBackend.h
	(expandToc): Add an entry for the master doc in child docs

	* src/buffer_funcs.C
	(setLabel): Add text class parameter
	(updateLabels): handle included docs if requested by the caller


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15904 a592a061-630c-0410-9148-cb99ea01b6c8
2006-11-13 16:53:49 +00:00
André Pönitz
6c300f72a2 move everything into namespace lyx
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15422 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-21 00:16:43 +00:00
Lars Gullik Bjønnes
2b01ca42d8 Move counters toward unicode.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15418 a592a061-630c-0410-9148-cb99ea01b6c8
2006-10-20 20:30:00 +00:00
Abdelrazak Younes
c5a4f61f33 This commit creates a error_lists map member inside the Buffer class.
I had no choice but to use string for the map key. This is
because the only information that could be passed to the controller is a
string.

With this new architecture, persistent error lists are now possible.

* Buffer
  - errorList_, addError(),  : deleted
  - std::map<std::string, ErrorList> errorLists_ : new member
  - errorList(std::string const & type): associated accessors

* buffer_funcs.C
  - bufferErrors(Buffer const & buf, TeXErrors const & terr): now needs a third errorList argument
  - bufferErrors(Buffer const & buf, ErrorList const & el): deleted.

* Converter
  - convert(): now needs an ErrorList argument instead of filling the Buffer errorList member directly.
  - runLaTeX(): ditto
  - scanLog(): ditto

* CutAndPaste.C
  - pasteParagraphList(): ditto
  - pasteSelection(): ditto

* lyxtext.h/text.C
  - readParagraph(): ditto
  - LyXText::read(): ditto

* importer:
  - Importer::Import(): ditto

* BufferView_pimpl.C
  - loadLyXFile(): send the Buffer::errors() signal instead of calling LyXView::showErrorList() directly.

* exporter.C
  - Export(): send the Buffer::errors() signal instead of calling LyXView::showErrorList() directly in lyxfunc.C

* ControlErrorList.C
  - initialiseParams(): translation operation transfered here from LyXView::showErrorList().

* LyXView.C
  - LoadLyXFile(): add a showErrorList("Parse") call.
  - showErrorList(): simplified due to code transferred to the ControlErrorList.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14652 a592a061-630c-0410-9148-cb99ea01b6c8
2006-08-13 16:16:43 +00:00
Abdelrazak Younes
f6bcac7285 * src/buffer_funcs.[Ch]
- updateCounters renamed to updateLabels
 - void updateLabels(Buffer const & buf,
   ParIterator & it): new convenience function
 - void updateLabels(Buffer const & buf,
   ParIterator & from, ParIterator & to): new convenience function
 - setCounter renamed to setLabel
 - bool tryToUpdateCurrentLabel(Buffer const & buf,
   ParIterator & it): new method
 - needsUpdateCounters: deleted

* src/BufferView_pimpl.C
* src/CutAndPaste.C
* src/frontends/controllers/ControlDocument.C
* src/lyxfunc.C
* src/text.C
* src/text2.C
* src/text3.C
 - fixed the calls to updateLabels


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13689 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-16 14:19:25 +00:00
Lars Gullik Bjønnes
cf4293824f * Change several freestanding and class methods with first letter
capitalized to have first letter lowercased.
* Adjust all affected files.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13605 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-09 00:26:19 +00:00
Abdelrazak Younes
4b0a5549b1 * buffer_funcs.[Ch]: new needsUpdateCounters function
* text.C:
 - LyXText::breakParagraph(): test if needsUpdateCounters() is enough before a full updateCounter
 - LyXText::backspacePos0(): ditto

* text2.C:
 - LyXText::deleteEmptyParagraphMechanism(): ditto


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13593 a592a061-630c-0410-9148-cb99ea01b6c8
2006-04-07 22:16:09 +00:00
Angus Leeming
70572847e2 Whitespace, only whitespace. s/ +$//
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10024 a592a061-630c-0410-9148-cb99ea01b6c8
2005-06-09 09:58:08 +00:00
Jean-Marc Lasgouttes
971d9986b7 fix bug 1807: New on-screen translations do not work
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9960 a592a061-630c-0410-9148-cb99ea01b6c8
2005-05-20 09:13:42 +00:00
Jean-Marc Lasgouttes
1e7112db43 fix counters updating mechanism
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9682 a592a061-630c-0410-9148-cb99ea01b6c8
2005-02-25 11:55:36 +00:00
Jean-Marc Lasgouttes
a839021d22 implement Word counting (bug 728)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9402 a592a061-630c-0410-9148-cb99ea01b6c8
2004-12-27 16:30:27 +00:00
Lars Gullik Bjønnes
44cd0fc9a1 The std::string mammoth path.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7862 a592a061-630c-0410-9148-cb99ea01b6c8
2003-10-06 15:43:21 +00:00
Angus Leeming
ffdb0baea3 Get rid of trailing whitespace 'noise' in future patches for the
forseeable future.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7724 a592a061-630c-0410-9148-cb99ea01b6c8
2003-09-09 18:27:24 +00:00
Angus Leeming
236ea81bc5 Replace LString.h with support/std_string.h,
Lsstream.h with support/std_sstream.h,
support/LIstream.h with support/std_istream.h,
support/LOstream.h with support/std_ostream.h.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7685 a592a061-630c-0410-9148-cb99ea01b6c8
2003-09-05 17:23:11 +00:00
Angus Leeming
0be0fcfd59 If I ever see another licence blurb again, it'll be too soon...
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7598 a592a061-630c-0410-9148-cb99ea01b6c8
2003-08-23 00:17:00 +00:00
Alfredo Braunstein
dfbd44997a moved some converter/format functions to more appropriate places
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7300 a592a061-630c-0410-9148-cb99ea01b6c8
2003-07-17 08:23:33 +00:00
Alfredo Braunstein
e3fc822783 Added new signals to Buffer, connect/disconnect to them in BufferView, added BufferView::newFile
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7242 a592a061-630c-0410-9148-cb99ea01b6c8
2003-07-07 08:37:02 +00:00
Alfredo Braunstein
3508b30871 More errorlist adjustements.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7209 a592a061-630c-0410-9148-cb99ea01b6c8
2003-06-24 20:42:15 +00:00
Alfredo Braunstein
2d8eb4b9d4 take several functions out of BufferList, and split functionality
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7195 a592a061-630c-0410-9148-cb99ea01b6c8
2003-06-20 12:46:28 +00:00