2010-02-26 16:54 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)

* contrib/hbide/resources/docviewgenerator.ui
  * contrib/hbide/resources/docviewgenerator.uic
    ! Enabled: left-right tab-widgets to share space as per user wish.
      You can resize the indivisual tab-widgets, move cursor in-between
      horizontal divider.

  * doc/hdr_tpl.txt
    ! Little correction in exact number of spaces and little 
      more awareness tip for writer.

  * contrib/hbide/ideharbourhelp.prg
  * contrib/hbide/idemisc.prg
    ! More refinements the way Harbour document is displayed.
      Please forward your suggessions.
    ! Presentation: documents tree is now exact syncronization with 
      Harbour's folder structure but depicting only those folders
      with /doc and /doc/en endingings.
    + Enabled: to reload the tree on the fly. Marco, check it.
This commit is contained in:
Pritpal Bedi
2010-02-27 01:02:40 +00:00
parent 6fba6b8a05
commit 2a225512dc
5 changed files with 657 additions and 557 deletions

View File

@@ -170,6 +170,7 @@ CLASS IdeHarbourHelp INHERIT IdeObject
METHOD create( oIde )
METHOD show()
METHOD destroy()
METHOD destroyTrees()
METHOD execEvent( nMode, p, p1 )
@@ -235,17 +236,27 @@ METHOD IdeHarbourHelp:show()
/*----------------------------------------------------------------------*/
METHOD IdeHarbourHelp:destroy()
LOCAL a_
IF empty( ::oUI )
RETURN Self
ENDIF
::destroyTrees()
::oUI:destroy()
RETURN Self
/*----------------------------------------------------------------------*/
METHOD IdeHarbourHelp:destroyTrees()
LOCAL a_
::disconnect( ::oUI:q_treeDoc, "itemSelectionChanged()" )
::disconnect( ::oUI:q_treeCategory, "itemSelectionChanged()" )
::aHistory := NIL
::aFuncByFile := NIL
::aHistory := {}
::aFuncByFile := {}
FOR EACH a_ IN ::aCategory
a_[ 4 ] := NIL // Reference to Contents node
@@ -276,13 +287,13 @@ METHOD IdeHarbourHelp:destroy()
IF !empty( ::aNodes )
::aNodes[ 1, 1 ] := NIL
ENDIF
::aNodes := NIL
::aNodes := {}
/* Index Tab */
FOR EACH a_ IN ::aFunctions
a_[ 5 ] := NIL
NEXT
::aFunctions := NIL
::aFunctions := {}
/* Category Tab */
FOR EACH a_ IN ::aCategory
@@ -296,9 +307,7 @@ METHOD IdeHarbourHelp:destroy()
a_[ 5 ] := NIL
ENDIF
NEXT
::aCategory := NIL
::oUI:destroy()
::aCategory := {}
RETURN Self
@@ -399,9 +408,6 @@ METHOD IdeHarbourHelp:installSignals()
::oUI:signal( "browserView" , "anchorClicked(QUrl)" , {|p| ::execEvent( browserView_anchorClicked, p ) } )
::oUI:signal( "tabWidgetContents", "currentChanged(int)" , {|p| ::execEvent( tabWidgetContents_currentChanged, p ) } )
::connect( ::oUI:q_treeDoc , "itemSelectionChanged()" , {| | ::execEvent( treeDoc_itemSelectionChanged ) } )
::connect( ::oUI:q_treeCategory , "itemSelectionChanged()" , {| | ::execEvent( treeCategory_itemSelectionChanged ) } )
RETURN Self
/*----------------------------------------------------------------------*/
@@ -562,21 +568,20 @@ METHOD IdeHarbourHelp:populateIndexedSelection()
/*----------------------------------------------------------------------*/
METHOD IdeHarbourHelp:refreshDocTree()
LOCAL aPaths, cFolder, cNFolder, aDocs, oTWItem, oParent, oParentF, cIcon
LOCAL aDir, a_, cTextFile, cStripped
LOCAL aPaths, cFolder, cNFolder, aDocs, oChild, oParent, oRoot, cRoot
LOCAL aDir, a_, cTextFile, n
IF empty( ::cPathInstall ) .OR. ! hb_dirExists( ::cPathInstall )
RETURN Self
ENDIF
IF !empty( ::aNodes )
RETURN Self
ENDIF
cIcon := ::resPath + "dc_folder.png"
/* Clean Environment */
::destroyTrees()
::oUI:q_treeDoc:clear()
//
::connect( ::oUI:q_treeDoc , "itemSelectionChanged()" , {| | ::execEvent( treeDoc_itemSelectionChanged ) } )
::connect( ::oUI:q_treeCategory, "itemSelectionChanged()" , {| | ::execEvent( treeCategory_itemSelectionChanged ) } )
//
::aNodes := {}
::aFuncByFile := {}
::aHistory := {}
@@ -587,6 +592,7 @@ METHOD IdeHarbourHelp:refreshDocTree()
aPaths := {}
aDocs := {}
hbide_fetchSubPaths( @aPaths, ::cPathInstall, .t. )
cRoot := aPaths[ 1 ]
FOR EACH cFolder IN aPaths
cNFolder := hbide_pathNormalized( cFolder, .t. )
@@ -595,48 +601,115 @@ METHOD IdeHarbourHelp:refreshDocTree()
ENDIF
NEXT
oTWItem := QTreeWidgetItem():new()
oTWItem:setText( 0, ::cPathInstall )
oTWItem:setIcon( 0, ::resPath + "dc_home.png" )
oTWItem:setToolTip( 0, ::cPathInstall )
oTWItem:setExpanded( .t. )
oRoot := QTreeWidgetItem():new()
oRoot:setText( 0, aPaths[ 1 ] )
oRoot:setIcon( 0, hbide_image( "dc_home" ) )
oRoot:setToolTip( 0, aPaths[ 1 ] )
oRoot:setExpanded( .t. )
::oUI:q_treeDoc:addTopLevelItem( oTWItem )
aadd( ::aNodes, { oTWItem, "Root", NIL /*oParent*/, ::cPathInstall, ::cPathInstall } )
oParent := oTWItem
::oUI:q_treeDoc:addTopLevelItem( oRoot )
aadd( ::aNodes, { oRoot, "Path", NIL, cRoot, cRoot } )
hbide_buildFoldersTree( ::aNodes, aDocs )
::aNodes[ 1,2 ] := "Root"
FOR EACH cFolder IN aDocs
oTWItem := QTreeWidgetItem():new()
oTWItem:setText( 0, ( cStripped := hbide_stripRoot( ::cPathInstall, cFolder ) ) )
oTWItem:setIcon( 0, cIcon )
oTWItem:setToolTip( 0, cFolder )
oParent:addChild( oTWItem )
aadd( ::aNodes, { oTWItem, "Path", oParent, cFolder, cStripped } )
IF ( n := ascan( ::aNodes, {|e_| e_[ 2 ] == "Path" .AND. lower( e_[ 4 ] ) == lower( cFolder ) } ) ) > 0
oParent := ::aNodes[ n, 1 ]
oParentF := oTWItem
aDir := directory( cFolder + "*.txt" )
FOR EACH a_ IN aDir
IF a_[ 5 ] != "D"
cTextFile := cFolder + a_[ 1 ]
oTWItem := QTreeWidgetItem():new()
oTWItem:setText( 0, a_[ 1 ] )
oTWItem:setIcon( 0, ::resPath + "dc_textdoc.png" )
oTWItem:setToolTip( 0, cTextFile )
oParentF:addChild( oTWItem )
aadd( ::aNodes, { oTWItem, "File", oParentF, cTextFile, a_[ 1 ] } )
::parseTextFile( cTextFile, oTWItem )
ENDIF
NEXT
aDir := directory( cFolder + "*.txt" )
FOR EACH a_ IN aDir
IF a_[ 5 ] != "D"
cTextFile := cFolder + a_[ 1 ]
oChild := QTreeWidgetItem():new()
oChild:setText( 0, a_[ 1 ] )
oChild:setIcon( 0, ::resPath + "dc_textdoc.png" )
oChild:setToolTip( 0, cTextFile )
oParent:addChild( oChild )
aadd( ::aNodes, { oChild, "File", oParent, cTextFile, a_[ 1 ] } )
::parseTextFile( cTextFile, oChild )
ENDIF
NEXT
ENDIF
NEXT
::populateIndex()
::oUI:q_treeDoc:expandItem( oParent )
::oUI:q_treeDoc:expandItem( oRoot )
RETURN Self
/*----------------------------------------------------------------------*/
STATIC FUNCTION hbide_buildFoldersTree( aNodes, aPaths )
LOCAL cRoot, cPath, s, aSubs, i, n, cCPath, cPPath, nP, cOSPath, oParent, oChild
LOCAL cIcon := hbide_image( "dc_folder" )
cRoot := aNodes[ 1, 4 ]
FOR EACH s IN aPaths
cPath := s
cPath := hbide_stripRoot( cRoot, cPath )
cPath := hbide_pathNormalized( cPath, .t. )
aSubs := hb_aTokens( cPath, "/" )
FOR i := 1 TO len( aSubs )
IF !empty( aSubs[ i ] )
cCPath := hbide_buildPathFromSubs( aSubs, i )
n := ascan( aNodes, {|e_| hbide_pathNormalized( e_[ 4 ], .t. ) == hbide_pathNormalized( cRoot + cCPath, .t. ) } )
IF n == 0
cPPath := hbide_buildPathFromSubs( aSubs, i - 1 )
nP := ascan( aNodes, {|e_| hbide_pathNormalized( e_[ 4 ], .t. ) == hbide_pathNormalized( cRoot + cPPath, .t. ) } )
oParent := aNodes[ nP, 1 ]
cOSPath := hbide_pathToOSPath( cRoot + cCPath )
oChild := QTreeWidgetItem():new()
oChild:setText( 0, aSubs[ i ] )
oChild:setIcon( 0, cIcon )
oChild:setToolTip( 0, cOSPath )
oParent:addChild( oChild )
aadd( aNodes, { oChild, "Path", oParent, cOSPath, aSubs[ i ] } )
ENDIF
ENDIF
NEXT
NEXT
RETURN NIL
/*----------------------------------------------------------------------*/
STATIC FUNCTION hbide_buildPathFromSubs( aSubs, nUpto )
LOCAL i, cPath := ""
IF nUpto > 0
FOR i := 1 TO nUpto
cPath += aSubs[ i ] + "/"
NEXT
ENDIF
RETURN cPath
/*----------------------------------------------------------------------*/
STATIC FUNCTION hbide_stripRoot( cRoot, cPath )
LOCAL cLRoot, cLPath, cP
cLRoot := hbide_pathNormalized( cRoot, .t. )
cLPath := hbide_pathNormalized( cPath, .t. )
IF left( cLPath, len( cLRoot ) ) == cLRoot
cP := substr( cLPath, len( cRoot ) + 1 )
RETURN cP
ENDIF
RETURN cPath
/*----------------------------------------------------------------------*/
METHOD IdeHarbourHelp:populateIndex()
LOCAL a_, qItem, oFunc, oParent, n
LOCAL aUnq := {}
@@ -945,7 +1018,7 @@ METHOD IdeHarbourHelp:populateFuncDetails( n )
/*----------------------------------------------------------------------*/
METHOD IdeHarbourHelp:buildView( oFunc )
LOCAL s, x, y, v, w, z, n, s1, a_
LOCAL s, x, y, v, w, z, n, s1, a_, cTxt
LOCAL aHtm := {}
aadd( aHtm, "<HTML>" )
@@ -992,8 +1065,22 @@ METHOD IdeHarbourHelp:buildView( oFunc )
aadd( aHtm, s )
aadd( aHtm, '<CAPTION align=TOP><FONT SIZE="6"><B>' + oFunc:cName + '</B></FONT></CAPTION>' )
aadd( aHtm, "<TR><TD align=CENTER ><B>" + oFunc:cOneLiner + "</B></TD></TR>" )
aadd( aHtm, '<BR><FONT color="#6699ff"><B>' + oFunc:cOneLiner + '</B></FONT></BR>' )
cTxt := " "
IF !empty( oFunc:cCategory )
cTxt += "Category: <B>" + oFunc:cCategory + "</B> "
ENDIF
IF !empty( oFunc:cSubCategory )
cTxt += "Sub: <B>" + oFunc:cSubCategory + "</B> "
ENDIF
IF !empty( oFunc:cVersion )
cTxt += "Version: <B>" + oFunc:cVersion + "</B> "
ENDIF
IF !empty( cTxt )
aadd( aHtm, "<BR>" + "[" + cTxt + "]" + "</BR>" )
ENDIF
//aadd( aHtm, '<HR color="#6699ff" width="90%" size="3"></HR>' )
aadd( aHtm, '<HR color="#6699ff" size="5"></HR>' )
x := '<TR><TD align=LEFT><font size="5" color="#FF4719">' ; y := "</font></TD></TR>"
v := '<TR><TD margin-left: 20px><pre>' ; w := "</pre></TD></TR>"
@@ -1004,42 +1091,59 @@ METHOD IdeHarbourHelp:buildView( oFunc )
aadd( aHtm, v + oFunc:cInherits + w )
aadd( aHtm, z )
ENDIF
aadd( aHtm, x + "Categoty" + y )
#if 0
aadd( aHtm, x + "Category" + y )
aadd( aHtm, v + oFunc:cCategory + w )
aadd( aHtm, z )
aadd( aHtm, x + "SubCategoty" + y )
aadd( aHtm, x + "SubCategory" + y )
aadd( aHtm, v + oFunc:cSubCategory+ w )
aadd( aHtm, z )
aadd( aHtm, x + "Syntax" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aSyntax ) + w )
aadd( aHtm, z )
aadd( aHtm, x + "Arguments" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aArguments ) + w )
aadd( aHtm, z )
aadd( aHtm, x + "Returns" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aReturns ) + w )
aadd( aHtm, z )
IF !empty( oFunc:aMethods )
aadd( aHtm, x + "Methods" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aMethods ) + w )
#endif
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aSyntax ) )
aadd( aHtm, x + "Syntax" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
aadd( aHtm, x + "Description" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aDescription ) + w )
aadd( aHtm, z )
aadd( aHtm, x + "Examples" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aExamples ) + w )
aadd( aHtm, z )
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aArguments ) )
aadd( aHtm, x + "Arguments" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aReturns ) )
aadd( aHtm, x + "Returns" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aMethods ) )
aadd( aHtm, x + "Methods" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aDescription ) )
aadd( aHtm, x + "Description" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aExamples ) )
aadd( aHtm, x + "Examples" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
#if 0
aadd( aHtm, x + "Vesrion" + y )
aadd( aHtm, v + oFunc:cVersion + w )
aadd( aHtm, z )
aadd( aHtm, x + "Files" + y )
aadd( aHtm, v + hbide_arrayToMemoHtml( oFunc:aFiles ) + w )
aadd( aHtm, z )
aadd( aHtm, x + "SeeAlso" + y )
aadd( aHtm, "<TR><TD>" )
#endif
IF !empty( s := hbide_arrayToMemoHtml( oFunc:aFiles ) )
aadd( aHtm, x + "Files" + y )
aadd( aHtm, v + s + w )
aadd( aHtm, z )
ENDIF
a_:= hb_atokens( oFunc:cSeaAlso, "," )
IF !empty( a_ )
aadd( aHtm, x + "SeeAlso" + y )
aadd( aHtm, "<TR><TD>" )
FOR EACH s IN a_
s := alltrim( s )
IF ( n := at( "(", s ) ) > 0
@@ -1047,20 +1151,22 @@ METHOD IdeHarbourHelp:buildView( oFunc )
ELSE
s1 := s
ENDIF
aadd( aHtm, '<a href="' + s1 + '">' + s + "</a>" + ;
aadd( aHtm, '<a href="' + s1 + '">' + s + "</a>" + ;
iif( s:__enumIndex() == len( a_ ), "", ",&nbsp;" ) )
NEXT
ELSE
aadd( aHtm, "&nbsp;" )
aadd( aHtm, "</TD></TR>" )
aadd( aHtm, z )
ENDIF
IF !empty( oFunc:cPlatforms )
aadd( aHtm, x + "Platforms" + y )
aadd( aHtm, v + oFunc:cPlatforms + w )
aadd( aHtm, z )
ENDIF
IF !empty( oFunc:cStatus )
aadd( aHtm, x + "Status" + y )
aadd( aHtm, v + oFunc:cStatus + w )
aadd( aHtm, z )
ENDIF
aadd( aHtm, "</TD></TR>" )
aadd( aHtm, z )
aadd( aHtm, x + "Platforms" + y )
aadd( aHtm, v + oFunc:cPlatforms + w )
aadd( aHtm, z )
aadd( aHtm, x + "Status" + y )
aadd( aHtm, v + oFunc:cStatus + w )
aadd( aHtm, z )
aadd( aHtm, " </TABLE>" )
aadd( aHtm, " </CENTER>" )

View File

@@ -1585,7 +1585,7 @@ FUNCTION hbide_fetchSubPaths( aPaths, cRootPath, lSubs )
aadd( aPaths, cRootPath )
IF lSubs
aDir := directory( cRootPath + "*.", "D" )
aDir := directory( cRootPath + "*", "D" )
FOR EACH a_ IN aDir
IF a_[ 5 ] == "D" .AND. left( a_[ 1 ], 1 ) != "."
hbide_fetchSubPaths( @aPaths, cRootPath + a_[ 1 ] )
@@ -1597,21 +1597,6 @@ FUNCTION hbide_fetchSubPaths( aPaths, cRootPath, lSubs )
/*----------------------------------------------------------------------*/
FUNCTION hbide_stripRoot( cRoot, cPath )
LOCAL cLRoot, cLPath, cP
cLRoot := hbide_pathNormalized( cRoot, .t. )
cLPath := hbide_pathNormalized( cPath, .t. )
IF left( cLPath, len( cLRoot ) ) == cLRoot
cP := substr( cLPath, len( cRoot ) + 2 )
RETURN cP
ENDIF
RETURN cPath
/*----------------------------------------------------------------------*/
FUNCTION hbide_image( cName )
RETURN hbide_pathToOsPath( hb_DirBase() + "resources" + "/" + cName + ".png" )
@@ -1621,3 +1606,18 @@ FUNCTION hbide_uic( cName )
RETURN hbide_pathToOsPath( hb_DirBase() + "resources" + "/" + cName + ".uic" )
/*----------------------------------------------------------------------*/
FUNCTION hbide_isPrevParent( cRoot, cPath )
LOCAL cLRoot, cLPath
cLRoot := hbide_pathNormalized( cRoot, .t. )
cLPath := hbide_pathNormalized( cPath, .t. )
IF left( cLPath, len( cLRoot ) ) == cLRoot
RETURN .t.
ENDIF
RETURN .f.
/*----------------------------------------------------------------------*/

View File

@@ -6,372 +6,15 @@
<rect>
<x>0</x>
<y>0</y>
<width>640</width>
<height>563</height>
<width>645</width>
<height>557</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<property name="leftMargin">
<number>2</number>
</property>
<property name="topMargin">
<number>4</number>
</property>
<property name="rightMargin">
<number>2</number>
</property>
<property name="bottomMargin">
<number>2</number>
</property>
<item row="2" column="0" colspan="2">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="labelInstall">
<property name="text">
<string>Harbour Installation Root:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="editInstall"/>
</item>
<item>
<widget class="QToolButton" name="buttonInstall">
<property name="text">
<string/>
</property>
<property name="autoRaise">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="labelDocPrefix">
<property name="text">
<string>Doc folder prefix:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="editDocPrefix">
<property name="maximumSize">
<size>
<width>70</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
</layout>
</item>
<item row="5" column="0">
<widget class="QTabWidget" name="tabWidgetContents">
<property name="maximumSize">
<size>
<width>200</width>
<height>16777215</height>
</size>
</property>
<property name="currentIndex">
<number>0</number>
</property>
<property name="documentMode">
<bool>false</bool>
</property>
<widget class="QWidget" name="tabContents">
<attribute name="title">
<string>Topics</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QTreeWidget" name="treeDoc">
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabByName">
<attribute name="title">
<string>Index</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QLineEdit" name="editIndex"/>
</item>
<item>
<widget class="QListWidget" name="listIndex"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabByCategory">
<attribute name="title">
<string>Category</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QTreeWidget" name="treeCategory">
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
</layout>
</widget>
</widget>
</item>
<item row="5" column="1">
<widget class="QTabWidget" name="tabWidgetElements">
<property name="currentIndex">
<number>0</number>
</property>
<widget class="QWidget" name="tabView">
<attribute name="title">
<string>View</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_8">
<item row="0" column="0">
<widget class="QTextBrowser" name="browserView"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabGeneral">
<attribute name="title">
<string>General</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Template:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="editTemplate"/>
</item>
<item row="0" column="2">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Name</string>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QLineEdit" name="editName"/>
</item>
<item row="1" column="2">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Category:</string>
</property>
</widget>
</item>
<item row="1" column="3">
<widget class="QLineEdit" name="editCategory"/>
</item>
<item row="2" column="2">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Sub-Category:</string>
</property>
</widget>
</item>
<item row="2" column="3">
<widget class="QLineEdit" name="editSubCategory"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>One-Liner</string>
</property>
</widget>
</item>
<item row="3" column="1" colspan="3">
<widget class="QLineEdit" name="editOneLiner"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Syntax:</string>
</property>
</widget>
</item>
<item row="4" column="1" colspan="3">
<widget class="QPlainTextEdit" name="plainSyntax"/>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_8">
<property name="text">
<string>Returns:</string>
</property>
</widget>
</item>
<item row="5" column="1" colspan="3">
<widget class="QLineEdit" name="editReturns"/>
</item>
<item row="6" column="2">
<widget class="QLabel" name="label_12">
<property name="text">
<string>Status:</string>
</property>
</widget>
</item>
<item row="6" column="3">
<widget class="QLineEdit" name="editStatus"/>
</item>
<item row="7" column="2">
<widget class="QLabel" name="label_13">
<property name="text">
<string>Platforms:</string>
</property>
</widget>
</item>
<item row="7" column="3">
<widget class="QLineEdit" name="editPlatforms"/>
</item>
<item row="8" column="0">
<widget class="QLabel" name="label_14">
<property name="text">
<string>Files:</string>
</property>
</widget>
</item>
<item row="8" column="1" colspan="3">
<widget class="QPlainTextEdit" name="plainFiles"/>
</item>
<item row="9" column="0">
<widget class="QLabel" name="label_15">
<property name="text">
<string>See Also:</string>
</property>
</widget>
</item>
<item row="9" column="1" colspan="3">
<widget class="QLineEdit" name="editSeeAlso"/>
</item>
<item row="10" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>.txt path:</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="3">
<widget class="QLineEdit" name="editTextPath"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabArguments">
<attribute name="title">
<string>Args</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="labelArgName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QLabel" name="labelArgDesc">
<property name="text">
<string>Description:</string>
</property>
</widget>
</item>
<item row="1" column="0" rowspan="4">
<widget class="QListWidget" name="listArguments">
<property name="maximumSize">
<size>
<width>150</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QToolButton" name="buttonArgPlus">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="1" column="2" rowspan="4">
<widget class="QPlainTextEdit" name="plainArgDesc"/>
</item>
<item row="2" column="1">
<widget class="QToolButton" name="buttonArgMinus">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QToolButton" name="buttonArgUp">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QToolButton" name="buttonArgDown">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="5" column="0" colspan="3">
<widget class="QPlainTextEdit" name="plainArguments">
<property name="readOnly">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabDesc">
<attribute name="title">
<string>Desc</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_4">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainDescription"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabExamples">
<attribute name="title">
<string>Examples</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_5">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainExamples"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabTests">
<attribute name="title">
<string>Tests</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_6">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainTests"/>
</item>
</layout>
</widget>
</widget>
</item>
<item row="0" column="0" colspan="2">
<item row="0" column="0">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QToolButton" name="buttonHome">
@@ -475,6 +118,354 @@
</item>
</layout>
</item>
<item row="1" column="0">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="labelInstall">
<property name="text">
<string>Harbour Installation Root:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="editInstall"/>
</item>
<item>
<widget class="QToolButton" name="buttonInstall">
<property name="text">
<string/>
</property>
<property name="autoRaise">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="labelDocPrefix">
<property name="text">
<string>Doc folder prefix:</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="editDocPrefix">
<property name="maximumSize">
<size>
<width>70</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
</layout>
</item>
<item row="2" column="0">
<widget class="QSplitter" name="splitter">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<widget class="QTabWidget" name="tabWidgetContents">
<property name="maximumSize">
<size>
<width>16777215</width>
<height>16777215</height>
</size>
</property>
<property name="currentIndex">
<number>0</number>
</property>
<property name="documentMode">
<bool>false</bool>
</property>
<widget class="QWidget" name="tabContents">
<attribute name="title">
<string>Topics</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QTreeWidget" name="treeDoc">
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabByName">
<attribute name="title">
<string>Index</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QLineEdit" name="editIndex"/>
</item>
<item>
<widget class="QListWidget" name="listIndex"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabByCategory">
<attribute name="title">
<string>Category</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<widget class="QTreeWidget" name="treeCategory">
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
</layout>
</widget>
</widget>
<widget class="QTabWidget" name="tabWidgetElements">
<property name="currentIndex">
<number>0</number>
</property>
<widget class="QWidget" name="tabView">
<attribute name="title">
<string>View</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_8">
<item row="0" column="0">
<widget class="QTextBrowser" name="browserView"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabGeneral">
<attribute name="title">
<string>General</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Template:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="editTemplate"/>
</item>
<item row="0" column="2">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Name</string>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QLineEdit" name="editName"/>
</item>
<item row="1" column="2">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Category:</string>
</property>
</widget>
</item>
<item row="1" column="3">
<widget class="QLineEdit" name="editCategory"/>
</item>
<item row="2" column="2">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Sub-Category:</string>
</property>
</widget>
</item>
<item row="2" column="3">
<widget class="QLineEdit" name="editSubCategory"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>One-Liner</string>
</property>
</widget>
</item>
<item row="3" column="1" colspan="3">
<widget class="QLineEdit" name="editOneLiner"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Syntax:</string>
</property>
</widget>
</item>
<item row="4" column="1" colspan="3">
<widget class="QPlainTextEdit" name="plainSyntax"/>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_8">
<property name="text">
<string>Returns:</string>
</property>
</widget>
</item>
<item row="5" column="1" colspan="3">
<widget class="QLineEdit" name="editReturns"/>
</item>
<item row="6" column="2">
<widget class="QLabel" name="label_12">
<property name="text">
<string>Status:</string>
</property>
</widget>
</item>
<item row="6" column="3">
<widget class="QLineEdit" name="editStatus"/>
</item>
<item row="7" column="2">
<widget class="QLabel" name="label_13">
<property name="text">
<string>Platforms:</string>
</property>
</widget>
</item>
<item row="7" column="3">
<widget class="QLineEdit" name="editPlatforms"/>
</item>
<item row="8" column="0">
<widget class="QLabel" name="label_14">
<property name="text">
<string>Files:</string>
</property>
</widget>
</item>
<item row="8" column="1" colspan="3">
<widget class="QPlainTextEdit" name="plainFiles"/>
</item>
<item row="9" column="0">
<widget class="QLabel" name="label_15">
<property name="text">
<string>See Also:</string>
</property>
</widget>
</item>
<item row="9" column="1" colspan="3">
<widget class="QLineEdit" name="editSeeAlso"/>
</item>
<item row="10" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>.txt path:</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="3">
<widget class="QLineEdit" name="editTextPath"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabArguments">
<attribute name="title">
<string>Args</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="labelArgName">
<property name="text">
<string>Name:</string>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QLabel" name="labelArgDesc">
<property name="text">
<string>Description:</string>
</property>
</widget>
</item>
<item row="1" column="0" rowspan="4">
<widget class="QListWidget" name="listArguments">
<property name="maximumSize">
<size>
<width>150</width>
<height>16777215</height>
</size>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QToolButton" name="buttonArgPlus">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="1" column="2" rowspan="4">
<widget class="QPlainTextEdit" name="plainArgDesc"/>
</item>
<item row="2" column="1">
<widget class="QToolButton" name="buttonArgMinus">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QToolButton" name="buttonArgUp">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QToolButton" name="buttonArgDown">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="5" column="0" colspan="3">
<widget class="QPlainTextEdit" name="plainArguments">
<property name="readOnly">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabDesc">
<attribute name="title">
<string>Desc</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_4">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainDescription"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabExamples">
<attribute name="title">
<string>Examples</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_5">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainExamples"/>
</item>
</layout>
</widget>
<widget class="QWidget" name="tabTests">
<attribute name="title">
<string>Tests</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_6">
<item row="0" column="0">
<widget class="QPlainTextEdit" name="plainTests"/>
</item>
</layout>
</widget>
</widget>
</widget>
</item>
</layout>
</widget>
<resources/>

View File

@@ -1,7 +1,7 @@
/********************************************************************************
** Form generated from reading ui file 'docviewgenerator.ui'
**
** Created: Wed Feb 24 16:25:24 2010
** Created: Fri Feb 26 00:25:50 2010
** by: Qt User Interface Compiler version 4.5.2
**
** WARNING! All changes made in this file will be lost when recompiling ui file!
@@ -22,6 +22,7 @@
#include <QtGui/QListWidget>
#include <QtGui/QPlainTextEdit>
#include <QtGui/QSpacerItem>
#include <QtGui/QSplitter>
#include <QtGui/QTabWidget>
#include <QtGui/QTextBrowser>
#include <QtGui/QToolButton>
@@ -35,12 +36,24 @@ class Ui_FormDocViewer
{
public:
QGridLayout *gridLayout;
QHBoxLayout *horizontalLayout_3;
QToolButton *buttonHome;
QToolButton *buttonBackward;
QToolButton *buttonForward;
QToolButton *buttonUp;
QToolButton *buttonRefresh;
QToolButton *buttonPrint;
QToolButton *buttonPdf;
QSpacerItem *horizontalSpacer_2;
QToolButton *buttonSave;
QToolButton *buttonExit;
QHBoxLayout *horizontalLayout;
QLabel *labelInstall;
QLineEdit *editInstall;
QToolButton *buttonInstall;
QLabel *labelDocPrefix;
QLineEdit *editDocPrefix;
QSplitter *splitter;
QTabWidget *tabWidgetContents;
QWidget *tabContents;
QVBoxLayout *verticalLayout;
@@ -102,26 +115,76 @@ public:
QWidget *tabTests;
QGridLayout *gridLayout_6;
QPlainTextEdit *plainTests;
QHBoxLayout *horizontalLayout_3;
QToolButton *buttonHome;
QToolButton *buttonBackward;
QToolButton *buttonForward;
QToolButton *buttonUp;
QToolButton *buttonRefresh;
QToolButton *buttonPrint;
QToolButton *buttonPdf;
QSpacerItem *horizontalSpacer_2;
QToolButton *buttonSave;
QToolButton *buttonExit;
void setupUi(QWidget *FormDocViewer)
{
if (FormDocViewer->objectName().isEmpty())
FormDocViewer->setObjectName(QString::fromUtf8("FormDocViewer"));
FormDocViewer->resize(640, 563);
FormDocViewer->resize(645, 557);
gridLayout = new QGridLayout(FormDocViewer);
gridLayout->setObjectName(QString::fromUtf8("gridLayout"));
gridLayout->setContentsMargins(2, 4, 2, 2);
horizontalLayout_3 = new QHBoxLayout();
horizontalLayout_3->setObjectName(QString::fromUtf8("horizontalLayout_3"));
buttonHome = new QToolButton(FormDocViewer);
buttonHome->setObjectName(QString::fromUtf8("buttonHome"));
buttonHome->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonHome);
buttonBackward = new QToolButton(FormDocViewer);
buttonBackward->setObjectName(QString::fromUtf8("buttonBackward"));
buttonBackward->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonBackward);
buttonForward = new QToolButton(FormDocViewer);
buttonForward->setObjectName(QString::fromUtf8("buttonForward"));
buttonForward->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonForward);
buttonUp = new QToolButton(FormDocViewer);
buttonUp->setObjectName(QString::fromUtf8("buttonUp"));
buttonUp->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonUp);
buttonRefresh = new QToolButton(FormDocViewer);
buttonRefresh->setObjectName(QString::fromUtf8("buttonRefresh"));
buttonRefresh->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonRefresh);
buttonPrint = new QToolButton(FormDocViewer);
buttonPrint->setObjectName(QString::fromUtf8("buttonPrint"));
buttonPrint->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonPrint);
buttonPdf = new QToolButton(FormDocViewer);
buttonPdf->setObjectName(QString::fromUtf8("buttonPdf"));
horizontalLayout_3->addWidget(buttonPdf);
horizontalSpacer_2 = new QSpacerItem(40, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
horizontalLayout_3->addItem(horizontalSpacer_2);
buttonSave = new QToolButton(FormDocViewer);
buttonSave->setObjectName(QString::fromUtf8("buttonSave"));
buttonSave->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonSave);
buttonExit = new QToolButton(FormDocViewer);
buttonExit->setObjectName(QString::fromUtf8("buttonExit"));
buttonExit->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonExit);
gridLayout->addLayout(horizontalLayout_3, 0, 0, 1, 1);
horizontalLayout = new QHBoxLayout();
horizontalLayout->setObjectName(QString::fromUtf8("horizontalLayout"));
labelInstall = new QLabel(FormDocViewer);
@@ -152,11 +215,14 @@ public:
horizontalLayout->addWidget(editDocPrefix);
gridLayout->addLayout(horizontalLayout, 2, 0, 1, 2);
gridLayout->addLayout(horizontalLayout, 1, 0, 1, 1);
tabWidgetContents = new QTabWidget(FormDocViewer);
splitter = new QSplitter(FormDocViewer);
splitter->setObjectName(QString::fromUtf8("splitter"));
splitter->setOrientation(Qt::Horizontal);
tabWidgetContents = new QTabWidget(splitter);
tabWidgetContents->setObjectName(QString::fromUtf8("tabWidgetContents"));
tabWidgetContents->setMaximumSize(QSize(200, 16777215));
tabWidgetContents->setMaximumSize(QSize(16777215, 16777215));
tabWidgetContents->setDocumentMode(false);
tabContents = new QWidget();
tabContents->setObjectName(QString::fromUtf8("tabContents"));
@@ -199,10 +265,8 @@ public:
verticalLayout_3->addWidget(treeCategory);
tabWidgetContents->addTab(tabByCategory, QString());
gridLayout->addWidget(tabWidgetContents, 5, 0, 1, 1);
tabWidgetElements = new QTabWidget(FormDocViewer);
splitter->addWidget(tabWidgetContents);
tabWidgetElements = new QTabWidget(splitter);
tabWidgetElements->setObjectName(QString::fromUtf8("tabWidgetElements"));
tabView = new QWidget();
tabView->setObjectName(QString::fromUtf8("tabView"));
@@ -421,70 +485,9 @@ public:
gridLayout_6->addWidget(plainTests, 0, 0, 1, 1);
tabWidgetElements->addTab(tabTests, QString());
splitter->addWidget(tabWidgetElements);
gridLayout->addWidget(tabWidgetElements, 5, 1, 1, 1);
horizontalLayout_3 = new QHBoxLayout();
horizontalLayout_3->setObjectName(QString::fromUtf8("horizontalLayout_3"));
buttonHome = new QToolButton(FormDocViewer);
buttonHome->setObjectName(QString::fromUtf8("buttonHome"));
buttonHome->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonHome);
buttonBackward = new QToolButton(FormDocViewer);
buttonBackward->setObjectName(QString::fromUtf8("buttonBackward"));
buttonBackward->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonBackward);
buttonForward = new QToolButton(FormDocViewer);
buttonForward->setObjectName(QString::fromUtf8("buttonForward"));
buttonForward->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonForward);
buttonUp = new QToolButton(FormDocViewer);
buttonUp->setObjectName(QString::fromUtf8("buttonUp"));
buttonUp->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonUp);
buttonRefresh = new QToolButton(FormDocViewer);
buttonRefresh->setObjectName(QString::fromUtf8("buttonRefresh"));
buttonRefresh->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonRefresh);
buttonPrint = new QToolButton(FormDocViewer);
buttonPrint->setObjectName(QString::fromUtf8("buttonPrint"));
buttonPrint->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonPrint);
buttonPdf = new QToolButton(FormDocViewer);
buttonPdf->setObjectName(QString::fromUtf8("buttonPdf"));
horizontalLayout_3->addWidget(buttonPdf);
horizontalSpacer_2 = new QSpacerItem(40, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
horizontalLayout_3->addItem(horizontalSpacer_2);
buttonSave = new QToolButton(FormDocViewer);
buttonSave->setObjectName(QString::fromUtf8("buttonSave"));
buttonSave->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonSave);
buttonExit = new QToolButton(FormDocViewer);
buttonExit->setObjectName(QString::fromUtf8("buttonExit"));
buttonExit->setAutoRaise(false);
horizontalLayout_3->addWidget(buttonExit);
gridLayout->addLayout(horizontalLayout_3, 0, 0, 1, 2);
gridLayout->addWidget(splitter, 2, 0, 1, 1);
retranslateUi(FormDocViewer);
@@ -499,6 +502,15 @@ public:
void retranslateUi(QWidget *FormDocViewer)
{
FormDocViewer->setWindowTitle(QApplication::translate("FormDocViewer", "Form", 0, QApplication::UnicodeUTF8));
buttonHome->setText(QString());
buttonBackward->setText(QString());
buttonForward->setText(QString());
buttonUp->setText(QString());
buttonRefresh->setText(QString());
buttonPrint->setText(QString());
buttonPdf->setText(QString());
buttonSave->setText(QString());
buttonExit->setText(QString());
labelInstall->setText(QApplication::translate("FormDocViewer", "Harbour Installation Root:", 0, QApplication::UnicodeUTF8));
buttonInstall->setText(QString());
labelDocPrefix->setText(QApplication::translate("FormDocViewer", "Doc folder prefix:", 0, QApplication::UnicodeUTF8));
@@ -529,15 +541,6 @@ public:
tabWidgetElements->setTabText(tabWidgetElements->indexOf(tabDesc), QApplication::translate("FormDocViewer", "Desc", 0, QApplication::UnicodeUTF8));
tabWidgetElements->setTabText(tabWidgetElements->indexOf(tabExamples), QApplication::translate("FormDocViewer", "Examples", 0, QApplication::UnicodeUTF8));
tabWidgetElements->setTabText(tabWidgetElements->indexOf(tabTests), QApplication::translate("FormDocViewer", "Tests", 0, QApplication::UnicodeUTF8));
buttonHome->setText(QString());
buttonBackward->setText(QString());
buttonForward->setText(QString());
buttonUp->setText(QString());
buttonRefresh->setText(QString());
buttonPrint->setText(QString());
buttonPdf->setText(QString());
buttonSave->setText(QString());
buttonExit->setText(QString());
Q_UNUSED(FormDocViewer);
} // retranslateUi

View File

@@ -76,7 +76,7 @@ FUNCTION HEADER TEMPLATE
/* $DOC$
$NAME$
StartHere()
$CATEGORY$
$SUBCATEGORY$
@@ -106,7 +106,7 @@ FUNCTION HEADER TEMPLATE
$FILES$
$SEEALSO$
comma separated list of references
Comma separated list of references
$END$
*/