On Fri, 2002-11-08 at 00:00, Andre Poenitz wrote:
>  Ben wrote
> > I will make a new patch.
> 
> Thank you.
> 
> Andr'e

Here it is. 

I think I could also move several methods in LyXtextclass from public to
private.

I intend next to do similar documentation on some other classes,
specifically things like LyXParagraph and related insets, and any
iterators.

I now intend to pragmatically set aside at arms length the ideal and
noble notions described previously and to understand and document the
non-ideal code!
Ben.

Index: src/ChangeLog
===================================================================
RCS file: /cvs/lyx/lyx-devel/src/ChangeLog,v
retrieving revision 1.972
diff -u -3 -p -u -r1.972 ChangeLog
--- src/ChangeLog	2002/11/07 00:37:08	1.972
+++ src/ChangeLog	2002/11/07 13:01:51
@@ -1,3 +1,7 @@
+2002-11-07  Ben Stanley  <[EMAIL PROTECTED]>
+
+	* lyxtextclass.[Ch]: revise and add doxygen comments
+
 2002-11-07  John Levon  <[EMAIL PROTECTED]>
 
 	* text.C: fix progress value for spellchecker 
Index: src/lyxtextclass.h
===================================================================
RCS file: /cvs/lyx/lyx-devel/src/lyxtextclass.h,v
retrieving revision 1.10
diff -u -3 -p -u -r1.10 lyxtextclass.h
--- src/lyxtextclass.h	2002/09/11 07:39:55	1.10
+++ src/lyxtextclass.h	2002/11/07 13:01:52
@@ -30,25 +30,25 @@ class LyXLex;
 class Counters;
 class FloatList;
 
-///
+/// Stores the layout specification of a LyX document class.
 class LyXTextClass {
 public:
-	///
+	/// The individual styles comprising the document class
 	typedef std::vector<LyXLayout_ptr> LayoutList;
-	///
+	/// Enumerate the paragraph styles.
 	typedef LayoutList::const_iterator const_iterator;
-	///
+	/// Construct a layout with default values. Actual values loaded later.
 	explicit
 	LyXTextClass(string const & = string(),
 		     string const & = string(),
 		     string const & = string());
 
-	///
+	/// paragraph styles begin iterator.
 	const_iterator begin() const { return layoutlist_.begin(); }
-	///
+	/// paragraph styles end iterator
 	const_iterator end() const { return layoutlist_.end(); }
 
-	///
+	/// Performs the read of the layout file.
 	bool Read(string const & filename, bool merge = false);
 	///
 	void readOutputType(LyXLex &);
@@ -69,11 +69,11 @@ public:
 	/// Sees to that the textclass structure has been loaded
 	bool load() const;
 
-	/// the list of floats defined in the class
+	/// the list of floats defined in the document class
 	FloatList & floats();
-	/// the list of floats defined in the class
+	/// the list of floats defined in the document class
 	FloatList const & floats() const;
-	/// The Counters present in this textclass.
+	/// The Counters present in this document class.
 	Counters & counters() const;
 	///
 	string const & defaultLayoutName() const;
@@ -128,7 +128,7 @@ public:
 	///
 	int tocdepth() const;
 
-	///
+	/// Can be LaTeX, LinuxDoc, etc.
 	OutputType outputType() const;
 
 	///
@@ -148,11 +148,11 @@ private:
 	bool delete_layout(string const &);
 	///
 	bool do_readStyle(LyXLex &, LyXLayout &);
-	///
+	/// Layout file name
 	string name_;
-	///
+	/// document class name
 	string latexname_;
-	///
+	/// document class description
 	string description_;
 	/// Specific class options
 	string opt_fontsize_;
@@ -164,19 +164,19 @@ private:
 	string pagestyle_;
 	///
 	string defaultlayout_;
-	///
+	/// preamble text to support layout styles
 	string preamble_;
-	///
+	/// latex packages loaded by document class.
 	Provides provides_;
 	///
 	unsigned int columns_;
 	///
 	PageSides sides_;
-	///
+	/// header depth to have numbering
 	int secnumdepth_;
-	///
+	/// header depth to appear in table of contents
 	int tocdepth_;
-	///
+	/// Can be LaTeX, LinuxDoc, etc.
 	OutputType outputType_;
 	/** Base font. The paragraph and layout fonts are resolved against
 	    this font. This has to be fully instantiated. Attributes
@@ -189,16 +189,16 @@ private:
 
 	/// Text that dictates how wide the right margin is on the screen
 	string rightmargin_;
-	///
+	/// highest header level used in this layout.
 	int maxcounter_; // add approp. signedness
 
-	///
+	/// Paragraph styles used in this layout
 	LayoutList layoutlist_;
 
-	///
+	/// available types of float, eg. figure, algorithm.
 	boost::shared_ptr<FloatList> floatlist_;
 
-	///
+	/// Types of counters, eg. sections, eqns, figures, avail. in document class.
 	boost::shared_ptr<Counters> ctrs_;
 
 	/// Has this layout file been loaded yet?
@@ -206,7 +206,7 @@ private:
 };
 
 
-///
+/// Merge two different provides flags into one bit field record
 inline
 void operator|=(LyXTextClass::Provides & p1, LyXTextClass::Provides p2)
 {
@@ -214,7 +214,7 @@ void operator|=(LyXTextClass::Provides &
 }
 
 
-///
+/// convert page sides option to text 1 or 2
 std::ostream & operator<<(std::ostream & os, LyXTextClass::PageSides p);
 
 #endif

Reply via email to