2010-01-21 23:59 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
* contrib/hbqt/generator/qt45.qtp
+ contrib/hbqt/qth/HBQPlainTextEdit.qth
* contrib/hbqt/qth/QApplication.qth
* contrib/hbqt/qth/QPlainTextEdit.qth
* contrib/hbqt/qtgui/filelist.mk
* contrib/hbqt/qtgui/QApplication.cpp
* contrib/hbqt/qtgui/QPlainTextEdit.cpp
+ contrib/hbqt/qtgui/HBQPlainTextEdit.cpp
+ contrib/hbqt/qtgui/THBQPlainTextEdit.prg
* contrib/hbqt/filelist.mk
* contrib/hbqt/hbqt.h
* contrib/hbqt/hbqt_garbage.h
* contrib/hbide/hbide.prg
* contrib/hbide/ideactions.prg
* contrib/hbide/idedocks.prg
* contrib/hbide/ideeditor.prg
* contrib/hbide/idemisc.prg
* contrib/hbide/ideobject.prg
* contrib/hbide/ideprojmanager.prg
* contrib/hbide/idesources.prg
+ Added HBQPlainTextEdit() class which implements some constructs
which were not possible in pure prg code. The underlying code has
been borrowed from TextEdit.c of QWriter - a work of
Gancov Kostya <kossne@mail.ru>, a big thank you. The code has been
extensively formatted and changed to adopt to Harbour standards.
The direct benefits by adopting this class are:
:
* Current line highlighting is absolutely ok now.
* Line numbers display is extremely fast and optimized.
* Book-marks are shown at the left of line-numbers.
* Parenthesis matching is absolutely delightful.
* To Upper/Lower implementation is accurate spanning many lines.
* Stream commenting is made possible.
* Book-marks management is smooth.
In IDE book-marks are implemented in different way than
most IDE's offer. Here is the description:
* Click on "Toggle Mark" icon on the toolbar.
* A small dot will appear on the left of current line.
* Look at status-bar, a small colored pushbutton will appear.
* Navigate the document as usual.
* Click on the colored push button staying in statusbar.
* The editing cursor will stay at book-mark represented by
that colored button and current line will appear highlighted
with the same color as that of button.
* Navigate to another location and click again on "Toggle Mark" icon.
* A new dot and one more colored button will appear in the statusbar.
* You can create 6 book marks as such and all will have different colors.
* You can click on any of desired usage.
* To delete a book-mark click on the button then "Toggle Mark"
* One button at the right will disappear.
* All tabs will contain their own book-marks.
* And every split window will have its own.
* Navigating different tabs or split windows will rearrange the
buttons according to its own settings.
; QUESTION : Is it worth the effort to save book-marks settings for next session?
This commit is contained in:
@@ -17,6 +17,70 @@
|
||||
past entries belonging to author(s): Viktor Szakats.
|
||||
*/
|
||||
|
||||
2010-01-21 23:59 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
|
||||
* contrib/hbqt/generator/qt45.qtp
|
||||
+ contrib/hbqt/qth/HBQPlainTextEdit.qth
|
||||
* contrib/hbqt/qth/QApplication.qth
|
||||
* contrib/hbqt/qth/QPlainTextEdit.qth
|
||||
|
||||
* contrib/hbqt/qtgui/filelist.mk
|
||||
* contrib/hbqt/qtgui/QApplication.cpp
|
||||
* contrib/hbqt/qtgui/QPlainTextEdit.cpp
|
||||
+ contrib/hbqt/qtgui/HBQPlainTextEdit.cpp
|
||||
+ contrib/hbqt/qtgui/THBQPlainTextEdit.prg
|
||||
|
||||
* contrib/hbqt/filelist.mk
|
||||
* contrib/hbqt/hbqt.h
|
||||
* contrib/hbqt/hbqt_garbage.h
|
||||
|
||||
* contrib/hbide/hbide.prg
|
||||
* contrib/hbide/ideactions.prg
|
||||
* contrib/hbide/idedocks.prg
|
||||
* contrib/hbide/ideeditor.prg
|
||||
* contrib/hbide/idemisc.prg
|
||||
* contrib/hbide/ideobject.prg
|
||||
* contrib/hbide/ideprojmanager.prg
|
||||
* contrib/hbide/idesources.prg
|
||||
|
||||
+ Added HBQPlainTextEdit() class which implements some constructs
|
||||
which were not possible in pure prg code. The underlying code has
|
||||
been borrowed from TextEdit.c of QWriter - a work of
|
||||
Gancov Kostya <kossne@mail.ru>, a big thank you. The code has been
|
||||
extensively formatted and changed to adopt to Harbour standards.
|
||||
|
||||
The direct benefits by adopting this class are:
|
||||
:
|
||||
* Current line highlighting is absolutely ok now.
|
||||
* Line numbers display is extremely fast and optimized.
|
||||
* Book-marks are shown at the left of line-numbers.
|
||||
* Parenthesis matching is absolutely delightful.
|
||||
* To Upper/Lower implementation is accurate spanning many lines.
|
||||
* Stream commenting is made possible.
|
||||
* Book-marks management is smooth.
|
||||
|
||||
In IDE book-marks are implemented in different way than
|
||||
most IDE's offer. Here is the description:
|
||||
* Click on "Toggle Mark" icon on the toolbar.
|
||||
* A small dot will appear on the left of current line.
|
||||
* Look at status-bar, a small colored pushbutton will appear.
|
||||
* Navigate the document as usual.
|
||||
* Click on the colored push button staying in statusbar.
|
||||
* The editing cursor will stay at book-mark represented by
|
||||
that colored button and current line will appear highlighted
|
||||
with the same color as that of button.
|
||||
* Navigate to another location and click again on "Toggle Mark" icon.
|
||||
* A new dot and one more colored button will appear in the statusbar.
|
||||
* You can create 6 book marks as such and all will have different colors.
|
||||
* You can click on any of desired usage.
|
||||
* To delete a book-mark click on the button then "Toggle Mark"
|
||||
* One button at the right will disappear.
|
||||
* All tabs will contain their own book-marks.
|
||||
* And every split window will have its own.
|
||||
* Navigating different tabs or split windows will rearrange the
|
||||
buttons according to its own settings.
|
||||
|
||||
; QUESTION : Is it worth the effort to save book-marks settings for next session?
|
||||
|
||||
2010-01-22 01:25 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* contrib/hbtip/sendmail.prg
|
||||
! Applied set of HB_SENDMAIL() patches sent by Francesco Perillo:
|
||||
|
||||
@@ -200,10 +200,11 @@ CLASS HbIde
|
||||
DATA aComments INIT {}
|
||||
DATA aProjects INIT {}
|
||||
|
||||
DATA aMarkTBtns INIT array( 6 )
|
||||
|
||||
METHOD new( cProjIni )
|
||||
METHOD create( cProjIni )
|
||||
METHOD destroy()
|
||||
METHOD execAction( cKey )
|
||||
METHOD setPosAndSizeByIni( qWidget, nPart )
|
||||
METHOD setPosByIni( qWidget, nPart )
|
||||
METHOD setSizeByIni( qWidget, nPart )
|
||||
@@ -219,6 +220,12 @@ CLASS HbIde
|
||||
METHOD updateTitleBar()
|
||||
METHOD setCodec( cCodec )
|
||||
|
||||
METHOD execAction( cKey )
|
||||
METHOD execProjectAction( cKey )
|
||||
METHOD execSourceAction( cKey )
|
||||
METHOD execEditorAction( cKey )
|
||||
METHOD execWindowsAction( cKey )
|
||||
|
||||
ENDCLASS
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
@@ -403,132 +410,74 @@ METHOD HbIde:create( cProjIni )
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:execAction( cKey )
|
||||
LOCAL aPrj, cHbi, cTmp, n
|
||||
|
||||
DO CASE
|
||||
CASE cKey == "Exit"
|
||||
SWITCH cKey
|
||||
CASE "Exit"
|
||||
PostAppEvent( xbeP_Close, NIL, NIL, ::oDlg )
|
||||
EXIT
|
||||
CASE "NewProject"
|
||||
CASE "LoadProject"
|
||||
CASE "LaunchProject"
|
||||
CASE "Build"
|
||||
CASE "BuildLaunch"
|
||||
CASE "Rebuild"
|
||||
CASE "RebuildLaunch"
|
||||
CASE "Compile"
|
||||
CASE "CompilePPO"
|
||||
CASE "Properties"
|
||||
CASE "SelectProject"
|
||||
CASE "CloseProject"
|
||||
::execProjectAction( cKey )
|
||||
EXIT
|
||||
CASE "New"
|
||||
CASE "Open"
|
||||
CASE "Save"
|
||||
CASE "SaveAs"
|
||||
CASE "SaveAll"
|
||||
CASE "SaveExit"
|
||||
CASE "Revert"
|
||||
CASE "Close"
|
||||
CASE "CloseAll"
|
||||
CASE "CloseOther"
|
||||
::execSourceAction( cKey )
|
||||
EXIT
|
||||
CASE "Print"
|
||||
CASE "Undo"
|
||||
CASE "Redo"
|
||||
CASE "Cut"
|
||||
CASE "Copy"
|
||||
CASE "Paste"
|
||||
CASE "SelectAll"
|
||||
CASE "DuplicateLine"
|
||||
CASE "BlockComment"
|
||||
CASE "StreamComment"
|
||||
CASE "switchReadOnly"
|
||||
CASE "Find"
|
||||
CASE "SetMark"
|
||||
CASE "GotoMark"
|
||||
CASE "Goto"
|
||||
CASE "ToUpper"
|
||||
CASE "ToLower"
|
||||
CASE "Invert"
|
||||
CASE "MatchPairs"
|
||||
CASE "InsertSeparator"
|
||||
CASE "InsertDateTime"
|
||||
CASE "InsertRandomName"
|
||||
CASE "InsertExternalFile"
|
||||
CASE "ZoomIn"
|
||||
CASE "ZoomOut"
|
||||
CASE "FormatBraces"
|
||||
CASE "RemoveTabs"
|
||||
CASE "RemoveTrailingSpaces"
|
||||
::execEditorAction( cKey )
|
||||
EXIT
|
||||
CASE "ToggleProjectTree"
|
||||
CASE "ToggleBuildInfo"
|
||||
CASE "ToggleFuncList"
|
||||
::execWindowsAction( cKey )
|
||||
EXIT
|
||||
|
||||
CASE cKey == "NewProject"
|
||||
::oPM:loadProperties( , .t., .t., .t. )
|
||||
CASE cKey == "LoadProject"
|
||||
::oPM:loadProperties( , .f., .f., .t. )
|
||||
CASE cKey == "LaunchProject"
|
||||
::oPM:launchProject()
|
||||
CASE cKey == "Build"
|
||||
::oPM:buildProject( '', .F., .F. )
|
||||
CASE cKey == "BuildLaunch"
|
||||
::oPM:buildProject( '', .T., .F. )
|
||||
CASE cKey == "Rebuild"
|
||||
::oPM:buildProject( '', .F., .T. )
|
||||
CASE cKey == "RebuildLaunch"
|
||||
::oPM:buildProject( '', .T., .T. )
|
||||
CASE cKey == "Compile"
|
||||
//
|
||||
CASE cKey == "CompilePPO"
|
||||
::oPM:buildProject( '', .F., .F., .T., .T. )
|
||||
CASE cKey == "Properties"
|
||||
IF Empty( ::cWrkProject )
|
||||
MsgBox( 'No active project detected' )
|
||||
ENDIF
|
||||
cTmp := ::oPM:getCurrentProject()
|
||||
IF ( n := ascan( ::aProjects, {|e_| e_[ 3, PRJ_PRP_PROPERTIES, 2, E_oPrjTtl ] == cTmp } ) ) > 0
|
||||
aPrj := ::aProjects[ n, 3 ]
|
||||
cHbi := aPrj[ PRJ_PRP_PROPERTIES, 2, PRJ_PRP_LOCATION ] + ::pathSep + ;
|
||||
aPrj[ PRJ_PRP_PROPERTIES, 2, PRJ_PRP_OUTPUT ] + ".hbi"
|
||||
|
||||
::oPM:loadProperties( cHbi, .f., .t., .t. )
|
||||
ELSE
|
||||
MsgBox( 'Invalid project: ' + cTmp )
|
||||
ENDIF
|
||||
CASE cKey == "SelectProject"
|
||||
::oPM:selectCurrentProject()
|
||||
CASE cKey == "CloseProject"
|
||||
::oPM:closeProject()
|
||||
|
||||
CASE cKey == "New"
|
||||
::oSM:editSource( '' )
|
||||
CASE cKey == "Open"
|
||||
::oSM:openSource()
|
||||
CASE cKey == "Save"
|
||||
::oSM:saveSource( ::oEM:getTabCurrent(), .f., .f. )
|
||||
CASE cKey == "SaveAs"
|
||||
::oSM:saveSource( ::oEM:getTabCurrent(), .t., .t. )
|
||||
CASE cKey == "SaveAll"
|
||||
::oSM:saveAllSources()
|
||||
CASE cKey == "SaveExit"
|
||||
::oSM:saveAndExit()
|
||||
CASE cKey == "Revert"
|
||||
::oSM:RevertSource()
|
||||
CASE cKey == "Close"
|
||||
::oSM:closeSource()
|
||||
CASE cKey == "CloseAll"
|
||||
::oSM:closeAllSources()
|
||||
CASE cKey == "CloseOther"
|
||||
::oSM:closeAllOthers()
|
||||
|
||||
CASE cKey == "Print"
|
||||
::oEM:printPreview()
|
||||
CASE cKey == "Undo"
|
||||
::oEM:undo()
|
||||
CASE cKey == "Redo"
|
||||
::oEM:redo()
|
||||
CASE cKey == "Cut"
|
||||
::oEM:cut()
|
||||
CASE cKey == "Copy"
|
||||
::oEM:copy()
|
||||
CASE cKey == "Paste"
|
||||
::oEM:paste()
|
||||
CASE cKey == "SelectAll"
|
||||
::oEM:selectAll()
|
||||
|
||||
CASE cKey == "switchReadOnly"
|
||||
::oEM:switchToReadOnly()
|
||||
CASE cKey == "Find"
|
||||
IF !Empty( ::qCurEdit )
|
||||
::oFR:show()
|
||||
ENDIF
|
||||
CASE cKey == "SetMark"
|
||||
::oEM:setMark()
|
||||
CASE cKey == "GotoMark"
|
||||
::oEM:gotoMark()
|
||||
CASE cKey == "Goto"
|
||||
::oEM:goTo()
|
||||
CASE cKey == "ToUpper"
|
||||
::oEM:convertSelection( cKey )
|
||||
CASE cKey == "ToLower"
|
||||
::oEM:convertSelection( cKey )
|
||||
CASE cKey == "Invert"
|
||||
::oEM:convertSelection( cKey )
|
||||
CASE cKey == "MatchPairs"
|
||||
//
|
||||
CASE cKey == "InsertSeparator"
|
||||
::oEM:insertSeparator()
|
||||
CASE cKey == "InsertDateTime"
|
||||
::oEM:insertText( cKey )
|
||||
CASE cKey == "InsertRandomName"
|
||||
::oEM:insertText( cKey )
|
||||
CASE cKey == "InsertExternalFile"
|
||||
::oEM:insertText( cKey )
|
||||
CASE cKey == "ZoomIn"
|
||||
::oEM:zoom( 1 )
|
||||
CASE cKey == "ZoomOut"
|
||||
::oEM:zoom( 0 )
|
||||
|
||||
CASE cKey == "FormatBraces"
|
||||
::oEM:formatBraces()
|
||||
CASE cKey == "RemoveTabs"
|
||||
::oEM:removeTabs()
|
||||
CASE cKey == "RemoveTrailingSpaces"
|
||||
::oEM:removeTrailingSpaces()
|
||||
|
||||
CASE cKey == "ToggleProjectTree"
|
||||
::oDK:toggleLeftDocks()
|
||||
CASE cKey == "ToggleBuildInfo"
|
||||
::oDK:toggleBottomDocks()
|
||||
CASE cKey == "ToggleFuncList"
|
||||
::oDK:toggleRightDocks()
|
||||
ENDCASE
|
||||
ENDSWITCH
|
||||
|
||||
::manageFocusInEditor()
|
||||
|
||||
@@ -536,6 +485,197 @@ METHOD HbIde:execAction( cKey )
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:execEditorAction( cKey )
|
||||
|
||||
SWITCH cKey
|
||||
CASE "Print"
|
||||
::oEM:printPreview()
|
||||
EXIT
|
||||
CASE "Undo"
|
||||
::oEM:undo()
|
||||
EXIT
|
||||
CASE "Redo"
|
||||
::oEM:redo()
|
||||
EXIT
|
||||
CASE "Cut"
|
||||
::oEM:cut()
|
||||
EXIT
|
||||
CASE "Copy"
|
||||
::oEM:copy()
|
||||
EXIT
|
||||
CASE "Paste"
|
||||
::oEM:paste()
|
||||
EXIT
|
||||
CASE "SelectAll"
|
||||
::oEM:selectAll()
|
||||
EXIT
|
||||
CASE "DuplicateLine"
|
||||
::oEM:duplicateLine()
|
||||
EXIT
|
||||
CASE "BlockComment"
|
||||
::oEM:blockComment()
|
||||
EXIT
|
||||
CASE "StreamComment"
|
||||
::oEM:streamComment()
|
||||
EXIT
|
||||
CASE "switchReadOnly"
|
||||
::oEM:switchToReadOnly()
|
||||
EXIT
|
||||
CASE "Find"
|
||||
IF !Empty( ::qCurEdit )
|
||||
::oFR:show()
|
||||
ENDIF
|
||||
EXIT
|
||||
CASE "SetMark"
|
||||
::oEM:setMark()
|
||||
EXIT
|
||||
CASE "GotoMark"
|
||||
::oEM:gotoMark()
|
||||
EXIT
|
||||
CASE "Goto"
|
||||
::oEM:goTo()
|
||||
EXIT
|
||||
CASE "ToUpper"
|
||||
::oEM:convertSelection( cKey )
|
||||
EXIT
|
||||
CASE "ToLower"
|
||||
::oEM:convertSelection( cKey )
|
||||
EXIT
|
||||
CASE "Invert"
|
||||
::oEM:convertSelection( cKey )
|
||||
EXIT
|
||||
CASE "MatchPairs"
|
||||
//
|
||||
EXIT
|
||||
CASE "InsertSeparator"
|
||||
::oEM:insertSeparator()
|
||||
EXIT
|
||||
CASE "InsertDateTime"
|
||||
::oEM:insertText( cKey )
|
||||
EXIT
|
||||
CASE "InsertRandomName"
|
||||
::oEM:insertText( cKey )
|
||||
EXIT
|
||||
CASE "InsertExternalFile"
|
||||
::oEM:insertText( cKey )
|
||||
EXIT
|
||||
CASE "ZoomIn"
|
||||
::oEM:zoom( 1 )
|
||||
EXIT
|
||||
CASE "ZoomOut"
|
||||
::oEM:zoom( 0 )
|
||||
EXIT
|
||||
CASE "FormatBraces"
|
||||
::oEM:formatBraces()
|
||||
EXIT
|
||||
CASE "RemoveTabs"
|
||||
::oEM:removeTabs()
|
||||
EXIT
|
||||
CASE "RemoveTrailingSpaces"
|
||||
::oEM:removeTrailingSpaces()
|
||||
EXIT
|
||||
ENDSWITCH
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:execSourceAction( cKey )
|
||||
SWITCH cKey
|
||||
CASE "New"
|
||||
::oSM:editSource( '' )
|
||||
EXIT
|
||||
CASE "Open"
|
||||
::oSM:openSource()
|
||||
EXIT
|
||||
CASE "Save"
|
||||
::oSM:saveSource( ::oEM:getTabCurrent(), .f., .f. )
|
||||
EXIT
|
||||
CASE "SaveAs"
|
||||
::oSM:saveSource( ::oEM:getTabCurrent(), .t., .t. )
|
||||
EXIT
|
||||
CASE "SaveAll"
|
||||
::oSM:saveAllSources()
|
||||
EXIT
|
||||
CASE "SaveExit"
|
||||
::oSM:saveAndExit()
|
||||
EXIT
|
||||
CASE "Revert"
|
||||
::oSM:RevertSource()
|
||||
EXIT
|
||||
CASE "Close"
|
||||
::oSM:closeSource()
|
||||
EXIT
|
||||
CASE "CloseAll"
|
||||
::oSM:closeAllSources()
|
||||
EXIT
|
||||
CASE "CloseOther"
|
||||
::oSM:closeAllOthers()
|
||||
EXIT
|
||||
ENDSWITCH
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:execProjectAction( cKey )
|
||||
SWITCH cKey
|
||||
CASE "NewProject"
|
||||
::oPM:loadProperties( , .t., .t., .t. )
|
||||
EXIT
|
||||
CASE "LoadProject"
|
||||
::oPM:loadProperties( , .f., .f., .t. )
|
||||
EXIT
|
||||
CASE "LaunchProject"
|
||||
::oPM:launchProject()
|
||||
EXIT
|
||||
CASE "Build"
|
||||
::oPM:buildProject( '', .F., .F. )
|
||||
EXIT
|
||||
CASE "BuildLaunch"
|
||||
::oPM:buildProject( '', .T., .F. )
|
||||
EXIT
|
||||
CASE "Rebuild"
|
||||
::oPM:buildProject( '', .F., .T. )
|
||||
EXIT
|
||||
CASE "RebuildLaunch"
|
||||
::oPM:buildProject( '', .T., .T. )
|
||||
EXIT
|
||||
CASE "Compile"
|
||||
//
|
||||
EXIT
|
||||
CASE "CompilePPO"
|
||||
::oPM:buildProject( '', .F., .F., .T., .T. )
|
||||
EXIT
|
||||
CASE "Properties"
|
||||
::oPM:getProperties()
|
||||
EXIT
|
||||
CASE "SelectProject"
|
||||
::oPM:selectCurrentProject()
|
||||
EXIT
|
||||
CASE "CloseProject"
|
||||
::oPM:closeProject()
|
||||
EXIT
|
||||
ENDSWITCH
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:execWindowsAction( cKey )
|
||||
|
||||
SWITCH cKey
|
||||
CASE "ToggleProjectTree"
|
||||
::oDK:toggleLeftDocks()
|
||||
EXIT
|
||||
CASE "ToggleBuildInfo"
|
||||
::oDK:toggleBottomDocks()
|
||||
EXIT
|
||||
CASE "ToggleFuncList"
|
||||
::oDK:toggleRightDocks()
|
||||
EXIT
|
||||
ENDSWITCH
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD HbIde:setPosAndSizeByIni( qWidget, nPart )
|
||||
LOCAL aRect
|
||||
|
||||
|
||||
@@ -197,7 +197,7 @@ METHOD IdeActions:loadActions()
|
||||
aadd( aAct, { "TB_SelectionMode" , "Toggle Selection Mode" , "stream" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_Find" , "~Find / Replace" , "find" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_Search" , "Search" , "search" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_SetMark" , "Set Mark" , "placeremovemark", "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_SetMark" , "Toggle Mark" , "placeremovemark", "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_GotoMark" , "Goto Mark" , "gotomark" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_Goto" , "~Goto Line" , "gotoline" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "TB_ToUpper" , "To Upper" , "toupper" , "" , "No", "Yes" } )
|
||||
@@ -287,8 +287,11 @@ METHOD IdeActions:loadActions()
|
||||
aadd( aAct, { "RebuildLaunchQt" , "Rebuild and Launch" , "rebuildlaunch" , "" , "No", "Yes" } )
|
||||
|
||||
aadd( aAct, { "RemoveTabs" , "Replace Tabs with Spaces" , "RemoveTabs" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "RemoveTrailingSpaces" , "Remove Trailing Spaces" , "RemoveTrailingSpaces", "" , "No", "Yes" } )
|
||||
aadd( aAct, { "RemoveTrailingSpaces" , "Remove Trailing Spaces" , "RemoveTrailingSpaces", "", "No", "Yes" } )
|
||||
aadd( aAct, { "FormatBraces" , "Format Braces" , "FormatBraces" , "" , "No", "Yes" } )
|
||||
aadd( aAct, { "DuplicateLine" , "Duplicate Current Line" , "DuplicateLine" , "^D" , "No", "Yes" } )
|
||||
aadd( aAct, { "StreamComment" , "Stream Comment" , "StreamComment" , "Sh+^Q", "No", "Yes" } )
|
||||
aadd( aAct, { "BlockComment" , "Block Comment" , "BlockComment" , "Sh+^/", "No", "Yes" } )
|
||||
|
||||
RETURN aAct
|
||||
|
||||
@@ -339,7 +342,7 @@ METHOD IdeActions:buildToolBar()
|
||||
oTBar:addItem( ::getAction( "TB_Search" ), , , , , , "Search" )
|
||||
oTBar:addItem( , , , , , nSep )
|
||||
oTBar:addItem( ::getAction( "TB_SetMark" ), , , , , , "SetMark" )
|
||||
oTBar:addItem( ::getAction( "TB_GotoMark" ), , , , , , "GotoMark" )
|
||||
* oTBar:addItem( ::getAction( "TB_GotoMark" ), , , , , , "GotoMark" )
|
||||
oTBar:addItem( ::getAction( "TB_Goto" ), , , , , , "Goto" )
|
||||
oTBar:addItem( , , , , , nSep )
|
||||
oTBar:addItem( ::getAction( "TB_ToUpper" ), , , , , , "ToUpper" )
|
||||
@@ -448,7 +451,10 @@ METHOD IdeActions:buildMainMenu()
|
||||
oSubMenu:addItem( { ::getAction( "Find" ), {|| oIde:execAction( "Find" ) } } )
|
||||
oSubMenu:addItem( { ::getAction( "Goto" ), {|| oIde:execAction( "Goto" ) } } )
|
||||
hbide_menuAddSep( oSubMenu )
|
||||
|
||||
oSubMenu:addItem( { ::getAction( "DuplicateLine" ), {|| oIde:execAction( "DuplicateLine" ) } } )
|
||||
oSubMenu:addItem( { ::getAction( "StreamComment" ), {|| oIde:execAction( "StreamComment" ) } } )
|
||||
oSubMenu:addItem( { ::getAction( "BlockComment" ), {|| oIde:execAction( "BlockComment" ) } } )
|
||||
hbide_menuAddSep( oSubMenu )
|
||||
oSubMenu2 := XbpMenu():new( oSubMenu ):create()
|
||||
oSubMenu2:addItem( { ::getAction( "InsertSeparator" ), {|| oIde:execAction( "InsertSeparator" ) } } )
|
||||
hbide_menuAddSep( oSubMenu )
|
||||
@@ -457,7 +463,6 @@ METHOD IdeActions:buildMainMenu()
|
||||
oSubMenu2:addItem( { ::getAction( "InsertExternalFile" ), {|| oIde:execAction( "InsertExternalFile" ) } } )
|
||||
oMenuBar:addItem( { oSubMenu2, _T( "~Insert" ) } )
|
||||
|
||||
hbide_menuAddSep( oSubMenu )
|
||||
oSubMenu2 := XbpMenu():new( oSubMenu ):create()
|
||||
oSubMenu2:addItem( { ::getAction( "RemoveTabs" ), {|| oIde:execAction( "RemoveTabs" ) } } )
|
||||
hbide_menuAddSep( oSubMenu )
|
||||
|
||||
@@ -93,6 +93,7 @@ CLASS IdeDockS INHERIT IdeObject
|
||||
METHOD toggleRightDocks()
|
||||
METHOD toggleBottomDocks()
|
||||
METHOD setStatusText( nPart, xValue )
|
||||
METHOD getMarkWidget( nIndex )
|
||||
|
||||
ENDCLASS
|
||||
|
||||
@@ -398,6 +399,7 @@ METHOD IdeDocks:outputDoubleClicked( lSelected )
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeDocks:buildStatusBar()
|
||||
LOCAL i
|
||||
|
||||
::oIde:oSBar := XbpStatusBar():new()
|
||||
::oSBar:create( ::oDlg, , { 0,0 }, { ::oDlg:currentSize()[ 1 ], 30 } )
|
||||
@@ -418,10 +420,30 @@ METHOD IdeDocks:buildStatusBar()
|
||||
::oSBar:addItem( "", , , , "Codec" ):oWidget:setMinimumWidth( 20 )
|
||||
::oSBar:addItem( "", , , , "Project" ):oWidget:setMinimumWidth( 20 )
|
||||
|
||||
FOR i := 1 TO 6
|
||||
::oSBar:oWidget:addWidget( ::getMarkWidget( i ) )
|
||||
NEXT
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeDocks:getMarkWidget( nIndex )
|
||||
LOCAL aColors := { "rgb( 255,255,127 )", "rgb( 175,175,255 )", "rgb( 255,175,175 )", ;
|
||||
"rgb( 175,255,175 )", "rgb( 255,190,125 )", "rgb( 175,255,255 )" }
|
||||
|
||||
::oIde:aMarkTBtns[ nIndex ] := QToolButton():new()
|
||||
|
||||
::oIde:aMarkTBtns[ nIndex ]:setMaximumHeight( 12 )
|
||||
::oIde:aMarkTBtns[ nIndex ]:setMaximumWidth( 12 )
|
||||
::oIde:aMarkTBtns[ nIndex ]:setStyleSheet( "background-color: " + aColors[ nIndex ] + ";" )
|
||||
::oIde:aMarkTBtns[ nIndex ]:hide()
|
||||
|
||||
::connect( ::oIde:aMarkTBtns[ nIndex ], "clicked()", {|| ::oEM:gotoMark( nIndex ) } )
|
||||
|
||||
RETURN ::oIde:aMarkTBtns[ nIndex ]
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeDocks:toggleLeftDocks()
|
||||
|
||||
IF ::lProjTreeVisible
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -514,7 +514,7 @@ FUNCTION hbide_isValidText( cSourceFile )
|
||||
hb_fNameSplit( cSourceFile, , , @cExt )
|
||||
|
||||
RETURN ( lower( cExt ) $ ".c,.cpp,.prg,.h,.ch,.txt,.log,.ini,.env,.ppo," + ;
|
||||
".cc,.hbc,.hbp,.hbm,.xml,.bat,.sh,.rc" )
|
||||
".cc,.hbc,.hbp,.hbm,.xml,.bat,.sh,.rc,.ui,.bak" )
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
@@ -764,7 +764,7 @@ FUNCTION hbide_parseKeyValPair( s, cKey, cVal )
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
FUNCTION hbide_dbg( ... )
|
||||
HB_TRACE( HB_TR_ALWAYS, ... )
|
||||
HB_TRACE( HB_TR_ALWAYS, procname(1),... )
|
||||
RETURN nil
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
@@ -143,6 +143,8 @@ CLASS IdeObject
|
||||
ACCESS lDockBVisible INLINE ::oIde:lDockBVisible
|
||||
ACCESS lTabCloseRequested INLINE ::oIde:lTabCloseRequested
|
||||
|
||||
ACCESS aMarkTBtns INLINE ::oIde:aMarkTBtns
|
||||
|
||||
DATA aSlots INIT {}
|
||||
DATA aEvents INIT {}
|
||||
METHOD connect( qWidget, cSlot, bBlock )
|
||||
|
||||
@@ -201,6 +201,7 @@ CLASS IdeProjManager INHERIT IdeObject
|
||||
METHOD populate()
|
||||
METHOD loadProperties( cProjFileName, lNew, lFetch, lUpdateTree )
|
||||
METHOD fetchProperties()
|
||||
METHOD getProperties()
|
||||
METHOD sortSources( cMode )
|
||||
METHOD updateMetaData()
|
||||
METHOD save( lCanClose )
|
||||
@@ -258,6 +259,27 @@ METHOD IdeProjManager:populate()
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeProjManager:getProperties()
|
||||
LOCAL aPrj, cHbi, cTmp, n
|
||||
|
||||
IF Empty( ::cWrkProject )
|
||||
MsgBox( 'No active project detected' )
|
||||
ENDIF
|
||||
cTmp := ::getCurrentProject()
|
||||
IF ( n := ascan( ::aProjects, {|e_| e_[ 3, PRJ_PRP_PROPERTIES, 2, E_oPrjTtl ] == cTmp } ) ) > 0
|
||||
aPrj := ::aProjects[ n, 3 ]
|
||||
cHbi := aPrj[ PRJ_PRP_PROPERTIES, 2, PRJ_PRP_LOCATION ] + ::pathSep + ;
|
||||
aPrj[ PRJ_PRP_PROPERTIES, 2, PRJ_PRP_OUTPUT ] + ".hbi"
|
||||
|
||||
::loadProperties( cHbi, .f., .t., .t. )
|
||||
ELSE
|
||||
MsgBox( 'Invalid project: ' + cTmp )
|
||||
ENDIF
|
||||
|
||||
RETURN Self
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeProjManager:loadProperties( cProjFileName, lNew, lFetch, lUpdateTree )
|
||||
LOCAL n, t, cWrkProject
|
||||
|
||||
|
||||
@@ -110,15 +110,15 @@ METHOD IdeSourcesManager:create( oIde )
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
METHOD IdeSourcesManager:loadSources()
|
||||
LOCAL a_
|
||||
LOCAL a_, nIndex
|
||||
|
||||
IF !empty( ::aIni[ INI_FILES ] )
|
||||
FOR EACH a_ IN ::aIni[ INI_FILES ]
|
||||
/* File nPos nVPos nHPos cTheme lAlert lVisible */
|
||||
::editSource( a_[ 1 ], a_[ 2 ], a_[ 3 ], a_[ 4 ], a_[ 5 ], .t., .f. )
|
||||
NEXT
|
||||
|
||||
::oEM:setSourceVisibleByIndex( val( ::aIni[ INI_HBIDE, RecentTabIndex ] ) )
|
||||
nIndex := max( 0, val( ::aIni[ INI_HBIDE, RecentTabIndex ] ) )
|
||||
::oEM:setSourceVisibleByIndex( nIndex )
|
||||
ENDIF
|
||||
|
||||
RETURN Self
|
||||
|
||||
@@ -6,6 +6,7 @@ MOC_HEADERS := \
|
||||
hbqt_hbdbfmodel.h \
|
||||
hbqt_hbevents.h \
|
||||
hbqt_hbqmainwindow.h \
|
||||
hbqt_hbqplaintextedit.h \
|
||||
hbqt_hbqsyntaxhighlighter.h \
|
||||
hbqt_hbqtableview.h \
|
||||
hbqt_hbslots.h \
|
||||
@@ -17,6 +18,7 @@ CPP_SOURCES := \
|
||||
hbqt_hbdbfmodel.cpp \
|
||||
hbqt_hbevents.cpp \
|
||||
hbqt_hbqmainwindow.cpp \
|
||||
hbqt_hbqplaintextedit.cpp \
|
||||
hbqt_hbqsyntaxhighlighter.cpp \
|
||||
hbqt_hbqtableview.cpp \
|
||||
hbqt_hbslots.cpp \
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
HBDbfModel.qth
|
||||
HBEvents.qth
|
||||
HBQPlainTextEdit.qth
|
||||
HBQSyntaxHighlighter.qth
|
||||
HBQTableView.qth
|
||||
HBQTextBlockUserData.qth
|
||||
|
||||
@@ -391,6 +391,7 @@ extern void * hbqt_pPtrFromItem( PHB_ITEM pObj );
|
||||
#define hbqt_par_HBDbfModel( n ) ( ( HBDbfModel * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBEvents( n ) ( ( HBEvents * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBQMainWindow( n ) ( ( HBQMainWindow * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBQPlainTextEdit( n ) ( ( HBQPlainTextEdit * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBQTableView( n ) ( ( HBQTableView * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBQSyntaxHighlighter( n ) ( ( HBQSyntaxHighlighter * ) hbqt_gcpointer( n ) )
|
||||
#define hbqt_par_HBQTextBlockUserData( n ) ( ( HBQTextBlockUserData * ) hbqt_gcpointer( n ) )
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBDbfModel );
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBEvents );
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBQPlainTextEdit );
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBQSyntaxHighlighter );
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBQTableView );
|
||||
extern QT_G_FUNC( hbqt_gcRelease_HBQTextBlockUserData );
|
||||
@@ -292,6 +293,7 @@ extern QT_G_FUNC( hbqt_gcRelease_QWizardPage );
|
||||
|
||||
extern void * hbqt_gcAllocate_HBDbfModel( void * pObj, bool bNew );
|
||||
extern void * hbqt_gcAllocate_HBEvents( void * pObj, bool bNew );
|
||||
extern void * hbqt_gcAllocate_HBQPlainTextEdit( void * pObj, bool bNew );
|
||||
extern void * hbqt_gcAllocate_HBQSyntaxHighlighter( void * pObj, bool bNew );
|
||||
extern void * hbqt_gcAllocate_HBQTableView( void * pObj, bool bNew );
|
||||
extern void * hbqt_gcAllocate_HBQTextBlockUserData( void * pObj, bool bNew );
|
||||
|
||||
368
harbour/contrib/hbqt/qtgui/HBQPlainTextEdit.cpp
Normal file
368
harbour/contrib/hbqt/qtgui/HBQPlainTextEdit.cpp
Normal file
@@ -0,0 +1,368 @@
|
||||
/*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* WARNING: Automatically generated source file. DO NOT EDIT! */
|
||||
/* Instead, edit corresponding .qth file, */
|
||||
/* or the generator tool itself, and run regenarate. */
|
||||
/* -------------------------------------------------------------------- */
|
||||
|
||||
/*
|
||||
* Harbour Project source code:
|
||||
* QT wrapper main header
|
||||
*
|
||||
* Copyright 2009-2010 Pritpal Bedi <pritpal@vouchcac.com>
|
||||
*
|
||||
* Copyright 2009 Marcos Antonio Gambeta <marcosgambeta at gmail dot com>
|
||||
* www - http://www.harbour-project.org
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2, or (at your option)
|
||||
* any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this software; see the file COPYING. If not, write to
|
||||
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
|
||||
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
|
||||
*
|
||||
* As a special exception, the Harbour Project gives permission for
|
||||
* additional uses of the text contained in its release of Harbour.
|
||||
*
|
||||
* The exception is that, if you link the Harbour libraries with other
|
||||
* files to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public License.
|
||||
* Your use of that executable is in no way restricted on account of
|
||||
* linking the Harbour library code into it.
|
||||
*
|
||||
* This exception does not however invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public License.
|
||||
*
|
||||
* This exception applies only to the code released by the Harbour
|
||||
* Project under the name Harbour. If you copy code from other
|
||||
* Harbour Project or Free Software Foundation releases into a copy of
|
||||
* Harbour, as the General Public License permits, the exception does
|
||||
* not apply to the code that you add in this way. To avoid misleading
|
||||
* anyone as to the status of such modified files, you must delete
|
||||
* this exception notice from them.
|
||||
*
|
||||
* If you write modifications of your own for Harbour, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
*
|
||||
*/
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
#include "hbapi.h"
|
||||
#include "../hbqt.h"
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
#if QT_VERSION >= 0x040500
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
#include <QtCore/QPointer>
|
||||
|
||||
#include <QtGui/QPlainTextEdit>
|
||||
|
||||
#include "../hbqt_hbqplaintextedit.h"
|
||||
|
||||
/*
|
||||
* HBQPlainTextEdit ( QWidget * parent = 0 )
|
||||
* HBQPlainTextEdit ( const QString & text, QWidget * parent = 0 )
|
||||
* virtual ~HBQPlainTextEdit ()
|
||||
*/
|
||||
|
||||
typedef struct
|
||||
{
|
||||
void * ph;
|
||||
bool bNew;
|
||||
QT_G_FUNC_PTR func;
|
||||
QPointer< HBQPlainTextEdit > pq;
|
||||
} QGC_POINTER_HBQPlainTextEdit;
|
||||
|
||||
QT_G_FUNC( hbqt_gcRelease_HBQPlainTextEdit )
|
||||
{
|
||||
QGC_POINTER_HBQPlainTextEdit * p = ( QGC_POINTER_HBQPlainTextEdit * ) Cargo;
|
||||
|
||||
if( p && p->bNew )
|
||||
{
|
||||
if( p->ph && p->pq )
|
||||
{
|
||||
const QMetaObject * m = ( ( QObject * ) p->ph )->metaObject();
|
||||
if( ( QString ) m->className() != ( QString ) "QObject" )
|
||||
{
|
||||
delete ( ( HBQPlainTextEdit * ) p->ph );
|
||||
HB_TRACE( HB_TR_DEBUG, ( "YES_rel_HBQPlainTextEdit ph=%p pq=%p %i B %i KB", p->ph, (void *)(p->pq), ( int ) hb_xquery( 1001 ), hbqt_getmemused() ) );
|
||||
p->ph = NULL;
|
||||
}
|
||||
else
|
||||
{
|
||||
HB_TRACE( HB_TR_DEBUG, ( "NO__rel_HBQPlainTextEdit ph=%p pq=%p %i B %i KB", p->ph, (void *)(p->pq), ( int ) hb_xquery( 1001 ), hbqt_getmemused() ) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
HB_TRACE( HB_TR_DEBUG, ( "DEL_rel_HBQPlainTextEdit Object already deleted!" ) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
HB_TRACE( HB_TR_DEBUG, ( "PTR_rel_HBQPlainTextEdit Object not created with - new" ) );
|
||||
p->ph = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void * hbqt_gcAllocate_HBQPlainTextEdit( void * pObj, bool bNew )
|
||||
{
|
||||
QGC_POINTER_HBQPlainTextEdit * p = ( QGC_POINTER_HBQPlainTextEdit * ) hb_gcAllocate( sizeof( QGC_POINTER_HBQPlainTextEdit ), hbqt_gcFuncs() );
|
||||
|
||||
p->ph = pObj;
|
||||
p->bNew = bNew;
|
||||
p->func = hbqt_gcRelease_HBQPlainTextEdit;
|
||||
|
||||
if( bNew )
|
||||
{
|
||||
new( & p->pq ) QPointer< HBQPlainTextEdit >( ( HBQPlainTextEdit * ) pObj );
|
||||
HB_TRACE( HB_TR_DEBUG, ( " _new_HBQPlainTextEdit ph=%p %i B %i KB", pObj, ( int ) hb_xquery( 1001 ), hbqt_getmemused() ) );
|
||||
}
|
||||
return p;
|
||||
}
|
||||
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT )
|
||||
{
|
||||
void * pObj = NULL;
|
||||
|
||||
if( hb_pcount() == 1 && HB_ISCHAR( 1 ) )
|
||||
{
|
||||
pObj = new HBQPlainTextEdit() ;
|
||||
}
|
||||
else if( hb_pcount() == 1 && HB_ISPOINTER( 1 ) )
|
||||
{
|
||||
pObj = new HBQPlainTextEdit( hbqt_par_QWidget( 1 ) ) ;
|
||||
}
|
||||
else
|
||||
{
|
||||
pObj = new HBQPlainTextEdit() ;
|
||||
}
|
||||
|
||||
hb_retptrGC( hbqt_gcAllocate_HBQPlainTextEdit( pObj, true ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* int getIndex( const QTextCursor & crQTextCursor)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_GETINDEX )
|
||||
{
|
||||
hb_retni( hbqt_par_HBQPlainTextEdit( 1 )->getIndex( *hbqt_par_QTextCursor( 2 ) ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* int getLine( const QTextCursor & crQTextCursor)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_GETLINE )
|
||||
{
|
||||
hb_retni( hbqt_par_HBQPlainTextEdit( 1 )->getLine( *hbqt_par_QTextCursor( 2 ) ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* int lineNumberAreaWidth()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_LINENUMBERAREAWIDTH )
|
||||
{
|
||||
hb_retni( hbqt_par_HBQPlainTextEdit( 1 )->lineNumberAreaWidth() );
|
||||
}
|
||||
|
||||
/*
|
||||
* int getSpaces()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_GETSPACES )
|
||||
{
|
||||
hb_retni( hbqt_par_HBQPlainTextEdit( 1 )->getSpaces() );
|
||||
}
|
||||
|
||||
/*
|
||||
* void setSpaces(int newSpaces)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_SETSPACES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->setSpaces( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void bookmarks(int block)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_BOOKMARKS )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->bookmarks( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void nextBookmark(int block)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_NEXTBOOKMARK )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->nextBookmark( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void prevBookmark(int block)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_PREVBOOKMARK )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->prevBookmark( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void gotoBookmark(int block)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_GOTOBOOKMARK )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->gotoBookmark( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void numberBlockVisible(bool b)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_NUMBERBLOCKVISIBLE )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->numberBlockVisible( hb_parl( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* bool numberBlockVisible()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_NUMBERBLOCKVISIBLE_1 )
|
||||
{
|
||||
hb_retl( hbqt_par_HBQPlainTextEdit( 1 )->numberBlockVisible() );
|
||||
}
|
||||
|
||||
/*
|
||||
* void highlightCurrentLine(bool b)
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_HIGHLIGHTCURRENTLINE )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->highlightCurrentLine( hb_parl( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* bool highlightCurrentLine()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_HIGHLIGHTCURRENTLINE_1 )
|
||||
{
|
||||
hb_retl( hbqt_par_HBQPlainTextEdit( 1 )->highlightCurrentLine() );
|
||||
}
|
||||
|
||||
/*
|
||||
* void updateLineNumberAreaWidth( int newBlockCount )
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_UPDATELINENUMBERAREAWIDTH )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->updateLineNumberAreaWidth( hb_parni( 2 ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* void caseUpper()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_CASEUPPER )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->caseUpper();
|
||||
}
|
||||
|
||||
/*
|
||||
* void caseLower()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_CASELOWER )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->caseLower();
|
||||
}
|
||||
|
||||
/*
|
||||
* void escapeQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_ESCAPEQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->escapeQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void escapeDQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_ESCAPEDQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->escapeDQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void unescapeQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_UNESCAPEQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->unescapeQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void unescapeDQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_UNESCAPEDQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->unescapeDQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void convertQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_CONVERTQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->convertQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void convertDQuotes()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_CONVERTDQUOTES )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->convertDQuotes();
|
||||
}
|
||||
|
||||
/*
|
||||
* void blockComment()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_BLOCKCOMMENT )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->blockComment();
|
||||
}
|
||||
|
||||
/*
|
||||
* void streamComment()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_STREAMCOMMENT )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->streamComment();
|
||||
}
|
||||
|
||||
/*
|
||||
* void duplicateLine()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_DUPLICATELINE )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->duplicateLine();
|
||||
}
|
||||
|
||||
/*
|
||||
* void replaceSelection( const QString & txt )
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT_REPLACESELECTION )
|
||||
{
|
||||
hbqt_par_HBQPlainTextEdit( 1 )->replaceSelection( HBQPlainTextEdit::tr( hb_parc( 2 ) ) );
|
||||
}
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
#endif /* #if QT_VERSION >= 0x040500 */
|
||||
/*----------------------------------------------------------------------*/
|
||||
@@ -89,6 +89,7 @@
|
||||
#include <qpalette.h>
|
||||
#include <QtGui/QApplication>
|
||||
#include <QtCore/QLocale>
|
||||
#include <QtCore/QTextCodec>
|
||||
#include <QtGui/QIcon>
|
||||
|
||||
static QApplication * s_app = NULL;
|
||||
@@ -124,6 +125,10 @@ static void hbqt_Init( void * cargo )
|
||||
{
|
||||
HB_SYMBOL_UNUSED( cargo );
|
||||
|
||||
QTextCodec *codec = QTextCodec::codecForLocale();
|
||||
QTextCodec::setCodecForTr( codec );
|
||||
QTextCodec::setCodecForCStrings( codec );
|
||||
|
||||
s_argc = hb_cmdargARGC();
|
||||
s_argv = hb_cmdargARGV();
|
||||
|
||||
|
||||
@@ -71,18 +71,13 @@
|
||||
*/
|
||||
|
||||
/*
|
||||
* Constructed[ 57/64 [ 89.06% ] ]
|
||||
* Constructed[ 57/59 [ 96.61% ] ]
|
||||
*
|
||||
* *** Unconvered Prototypes ***
|
||||
* -----------------------------
|
||||
*
|
||||
* QList<QTextEdit::ExtraSelection> extraSelections () const
|
||||
* void setExtraSelections ( const QList<QTextEdit::ExtraSelection> & selections )
|
||||
* 15 public functions inherited from QAbstractScrollArea
|
||||
* 13 public functions inherited from QFrame
|
||||
* 207 public functions inherited from QWidget
|
||||
* 29 public functions inherited from QObject
|
||||
* 12 public functions inherited from QPaintDevice
|
||||
*/
|
||||
|
||||
#include <QtCore/QPointer>
|
||||
|
||||
211
harbour/contrib/hbqt/qtgui/THBQPlainTextEdit.prg
Normal file
211
harbour/contrib/hbqt/qtgui/THBQPlainTextEdit.prg
Normal file
@@ -0,0 +1,211 @@
|
||||
/*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* WARNING: Automatically generated source file. DO NOT EDIT! */
|
||||
/* Instead, edit corresponding .qth file, */
|
||||
/* or the generator tool itself, and run regenarate. */
|
||||
/* -------------------------------------------------------------------- */
|
||||
|
||||
/*
|
||||
* Harbour Project source code:
|
||||
* QT wrapper main header
|
||||
*
|
||||
* Copyright 2009-2010 Pritpal Bedi <pritpal@vouchcac.com>
|
||||
*
|
||||
* Copyright 2009 Marcos Antonio Gambeta <marcosgambeta at gmail dot com>
|
||||
* www - http://www.harbour-project.org
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2, or (at your option)
|
||||
* any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this software; see the file COPYING. If not, write to
|
||||
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
|
||||
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
|
||||
*
|
||||
* As a special exception, the Harbour Project gives permission for
|
||||
* additional uses of the text contained in its release of Harbour.
|
||||
*
|
||||
* The exception is that, if you link the Harbour libraries with other
|
||||
* files to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public License.
|
||||
* Your use of that executable is in no way restricted on account of
|
||||
* linking the Harbour library code into it.
|
||||
*
|
||||
* This exception does not however invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public License.
|
||||
*
|
||||
* This exception applies only to the code released by the Harbour
|
||||
* Project under the name Harbour. If you copy code from other
|
||||
* Harbour Project or Free Software Foundation releases into a copy of
|
||||
* Harbour, as the General Public License permits, the exception does
|
||||
* not apply to the code that you add in this way. To avoid misleading
|
||||
* anyone as to the status of such modified files, you must delete
|
||||
* this exception notice from them.
|
||||
*
|
||||
* If you write modifications of your own for Harbour, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
*
|
||||
*/
|
||||
/*----------------------------------------------------------------------*/
|
||||
|
||||
|
||||
#include "hbclass.ch"
|
||||
|
||||
|
||||
CREATE CLASS HBQPlainTextEdit INHERIT HbQtObjectHandler, QPlainTextEdit
|
||||
|
||||
METHOD new( ... )
|
||||
|
||||
METHOD getIndex( pCrQTextCursor )
|
||||
METHOD getLine( pCrQTextCursor )
|
||||
METHOD lineNumberAreaWidth()
|
||||
METHOD getSpaces()
|
||||
METHOD setSpaces( nNewSpaces )
|
||||
METHOD bookmarks( nBlock )
|
||||
METHOD nextBookmark( nBlock )
|
||||
METHOD prevBookmark( nBlock )
|
||||
METHOD gotoBookmark( nBlock )
|
||||
METHOD numberBlockVisible( lB )
|
||||
METHOD numberBlockVisible_1()
|
||||
METHOD highlightCurrentLine( lB )
|
||||
METHOD highlightCurrentLine_1()
|
||||
METHOD updateLineNumberAreaWidth( nNewBlockCount )
|
||||
METHOD caseUpper()
|
||||
METHOD caseLower()
|
||||
METHOD escapeQuotes()
|
||||
METHOD escapeDQuotes()
|
||||
METHOD unescapeQuotes()
|
||||
METHOD unescapeDQuotes()
|
||||
METHOD convertQuotes()
|
||||
METHOD convertDQuotes()
|
||||
METHOD blockComment()
|
||||
METHOD streamComment()
|
||||
METHOD duplicateLine()
|
||||
METHOD replaceSelection( cTxt )
|
||||
|
||||
ENDCLASS
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:new( ... )
|
||||
LOCAL p
|
||||
FOR EACH p IN { ... }
|
||||
hb_pvalue( p:__enumIndex(), hbqt_ptr( p ) )
|
||||
NEXT
|
||||
::pPtr := Qt_HBQPlainTextEdit( ... )
|
||||
RETURN Self
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:getIndex( pCrQTextCursor )
|
||||
RETURN Qt_HBQPlainTextEdit_getIndex( ::pPtr, hbqt_ptr( pCrQTextCursor ) )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:getLine( pCrQTextCursor )
|
||||
RETURN Qt_HBQPlainTextEdit_getLine( ::pPtr, hbqt_ptr( pCrQTextCursor ) )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:lineNumberAreaWidth()
|
||||
RETURN Qt_HBQPlainTextEdit_lineNumberAreaWidth( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:getSpaces()
|
||||
RETURN Qt_HBQPlainTextEdit_getSpaces( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:setSpaces( nNewSpaces )
|
||||
RETURN Qt_HBQPlainTextEdit_setSpaces( ::pPtr, nNewSpaces )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:bookmarks( nBlock )
|
||||
RETURN Qt_HBQPlainTextEdit_bookmarks( ::pPtr, nBlock )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:nextBookmark( nBlock )
|
||||
RETURN Qt_HBQPlainTextEdit_nextBookmark( ::pPtr, nBlock )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:prevBookmark( nBlock )
|
||||
RETURN Qt_HBQPlainTextEdit_prevBookmark( ::pPtr, nBlock )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:gotoBookmark( nBlock )
|
||||
RETURN Qt_HBQPlainTextEdit_gotoBookmark( ::pPtr, nBlock )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:numberBlockVisible( lB )
|
||||
RETURN Qt_HBQPlainTextEdit_numberBlockVisible( ::pPtr, lB )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:numberBlockVisible_1()
|
||||
RETURN Qt_HBQPlainTextEdit_numberBlockVisible_1( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:highlightCurrentLine( lB )
|
||||
RETURN Qt_HBQPlainTextEdit_highlightCurrentLine( ::pPtr, lB )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:highlightCurrentLine_1()
|
||||
RETURN Qt_HBQPlainTextEdit_highlightCurrentLine_1( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:updateLineNumberAreaWidth( nNewBlockCount )
|
||||
RETURN Qt_HBQPlainTextEdit_updateLineNumberAreaWidth( ::pPtr, nNewBlockCount )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:caseUpper()
|
||||
RETURN Qt_HBQPlainTextEdit_caseUpper( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:caseLower()
|
||||
RETURN Qt_HBQPlainTextEdit_caseLower( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:escapeQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_escapeQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:escapeDQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_escapeDQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:unescapeQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_unescapeQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:unescapeDQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_unescapeDQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:convertQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_convertQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:convertDQuotes()
|
||||
RETURN Qt_HBQPlainTextEdit_convertDQuotes( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:blockComment()
|
||||
RETURN Qt_HBQPlainTextEdit_blockComment( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:streamComment()
|
||||
RETURN Qt_HBQPlainTextEdit_streamComment( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:duplicateLine()
|
||||
RETURN Qt_HBQPlainTextEdit_duplicateLine( ::pPtr )
|
||||
|
||||
|
||||
METHOD HBQPlainTextEdit:replaceSelection( cTxt )
|
||||
RETURN Qt_HBQPlainTextEdit_replaceSelection( ::pPtr, cTxt )
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
# --------------------------------------------------------------------
|
||||
|
||||
CPP_SOURCES := \
|
||||
HBQPlainTextEdit.cpp \
|
||||
HBQSyntaxHighlighter.cpp \
|
||||
HBQTableView.cpp \
|
||||
HBQTextBlockUserData.cpp \
|
||||
@@ -226,6 +227,7 @@ CPP_SOURCES := \
|
||||
|
||||
|
||||
PRG_SOURCES := \
|
||||
THBQPlainTextEdit.prg \
|
||||
THBQSyntaxHighlighter.prg \
|
||||
THBQTableView.prg \
|
||||
THBQTextBlockUserData.prg \
|
||||
|
||||
130
harbour/contrib/hbqt/qth/HBQPlainTextEdit.qth
Normal file
130
harbour/contrib/hbqt/qth/HBQPlainTextEdit.qth
Normal file
@@ -0,0 +1,130 @@
|
||||
/*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/*
|
||||
* Harbour Project source code:
|
||||
* QT Source Generator for Harbour
|
||||
*
|
||||
* Copyright 2009 Pritpal Bedi <pritpal@vouchcac.com>
|
||||
* www - http://www.harbour-project.org
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2, or (at your option)
|
||||
* any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this software; see the file COPYING. If not, write to
|
||||
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
|
||||
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
|
||||
*
|
||||
* As a special exception, the Harbour Project gives permission for
|
||||
* additional uses of the text contained in its release of Harbour.
|
||||
*
|
||||
* The exception is that, if you link the Harbour libraries with other
|
||||
* files to produce an executable, this does not by itself cause the
|
||||
* resulting executable to be covered by the GNU General Public License.
|
||||
* Your use of that executable is in no way restricted on account of
|
||||
* linking the Harbour library code into it.
|
||||
*
|
||||
* This exception does not however invalidate any other reasons why
|
||||
* the executable file might be covered by the GNU General Public License.
|
||||
*
|
||||
* This exception applies only to the code released by the Harbour
|
||||
* Project under the name Harbour. If you copy code from other
|
||||
* Harbour Project or Free Software Foundation releases into a copy of
|
||||
* Harbour, as the General Public License permits, the exception does
|
||||
* not apply to the code that you add in this way. To avoid misleading
|
||||
* anyone as to the status of such modified files, you must delete
|
||||
* this exception notice from them.
|
||||
*
|
||||
* If you write modifications of your own for Harbour, it is your choice
|
||||
* whether to permit this exception to apply to your modifications.
|
||||
* If you do not wish that, delete this exception notice.
|
||||
*
|
||||
*/
|
||||
/*----------------------------------------------------------------------*/
|
||||
;
|
||||
; Header File to Generate QT Wrapper Sources
|
||||
;
|
||||
|
||||
<CLASS>
|
||||
QObject =
|
||||
Inherits = QPlainTextEdit
|
||||
Type =
|
||||
New =
|
||||
</CLASS>
|
||||
|
||||
<DOC>
|
||||
</DOC>
|
||||
|
||||
<CODE>
|
||||
#include <QtGui/QPlainTextEdit>
|
||||
|
||||
#include "../hbqt_hbqplaintextedit.h"
|
||||
|
||||
/*
|
||||
* HBQPlainTextEdit ( QWidget * parent = 0 )
|
||||
* HBQPlainTextEdit ( const QString & text, QWidget * parent = 0 )
|
||||
* virtual ~HBQPlainTextEdit ()
|
||||
*/
|
||||
HB_FUNC( QT_HBQPLAINTEXTEDIT )
|
||||
{
|
||||
if( hb_pcount() == 1 && HB_ISCHAR( 1 ) )
|
||||
{
|
||||
hb_retptr( new HBQPlainTextEdit() );
|
||||
}
|
||||
else if( hb_pcount() == 1 && HB_ISPOINTER( 1 ) )
|
||||
{
|
||||
hb_retptr( new HBQPlainTextEdit( hbqt_par_QWidget( 1 ) ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
hb_retptr( new HBQPlainTextEdit() );
|
||||
}
|
||||
}
|
||||
</CODE>
|
||||
|
||||
<ENUMS>
|
||||
</ENUMS>
|
||||
|
||||
<PROTOS>
|
||||
int getIndex( const QTextCursor & crQTextCursor)
|
||||
int getLine( const QTextCursor & crQTextCursor)
|
||||
int lineNumberAreaWidth()
|
||||
int getSpaces()
|
||||
void setSpaces(int newSpaces)
|
||||
void bookmarks(int block)
|
||||
void nextBookmark(int block)
|
||||
void prevBookmark(int block)
|
||||
void gotoBookmark(int block)
|
||||
void numberBlockVisible(bool b)
|
||||
bool numberBlockVisible()
|
||||
void highlightCurrentLine(bool b)
|
||||
bool highlightCurrentLine()
|
||||
</PROTOS>
|
||||
|
||||
<SLOTS>
|
||||
void updateLineNumberAreaWidth( int newBlockCount )
|
||||
void caseUpper()
|
||||
void caseLower()
|
||||
void escapeQuotes()
|
||||
void escapeDQuotes()
|
||||
void unescapeQuotes()
|
||||
void unescapeDQuotes()
|
||||
void convertQuotes()
|
||||
void convertDQuotes()
|
||||
void blockComment()
|
||||
void streamComment()
|
||||
void duplicateLine()
|
||||
void replaceSelection( const QString & txt )
|
||||
</SLOTS>
|
||||
|
||||
<SIGNALS>
|
||||
</SIGNALS>
|
||||
@@ -76,6 +76,7 @@ New =
|
||||
#include <qpalette.h>
|
||||
#include <QtGui/QApplication>
|
||||
#include <QtCore/QLocale>
|
||||
#include <QtCore/QTextCodec>
|
||||
#include <QtGui/QIcon>
|
||||
|
||||
static QApplication * s_app = NULL;
|
||||
@@ -115,6 +116,10 @@ static void hbqt_Init( void * cargo )
|
||||
{
|
||||
HB_SYMBOL_UNUSED( cargo );
|
||||
|
||||
QTextCodec *codec = QTextCodec::codecForLocale();
|
||||
QTextCodec::setCodecForTr( codec );
|
||||
QTextCodec::setCodecForCStrings( codec );
|
||||
|
||||
s_argc = hb_cmdargARGC();
|
||||
s_argv = hb_cmdargARGV();
|
||||
|
||||
|
||||
@@ -146,11 +146,6 @@ QTextCursor textCursor () const
|
||||
Qt::TextInteractionFlags textInteractionFlags () const
|
||||
QString toPlainText () const
|
||||
QTextOption::WrapMode wordWrapMode () const
|
||||
15 public functions inherited from QAbstractScrollArea
|
||||
13 public functions inherited from QFrame
|
||||
207 public functions inherited from QWidget
|
||||
29 public functions inherited from QObject
|
||||
12 public functions inherited from QPaintDevice
|
||||
</PROTOS>
|
||||
|
||||
<SLOTS>
|
||||
|
||||
Reference in New Issue
Block a user