aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <nyamatongwe@gmail.com>2013-08-07 19:19:03 +1000
committernyamatongwe <nyamatongwe@gmail.com>2013-08-07 19:19:03 +1000
commit8cf888545b78221b3c27c8dc4601522332157b68 (patch)
tree2225a0c742a6c98d77eb13412c76295204f61551
parent66f5c01b41959d02736255df0572e2cbfa18a18b (diff)
downloadscintilla-mirror-8cf888545b78221b3c27c8dc4601522332157b68.tar.gz
Bindings in ScintillaEdit made to work on 64-bit Unix systems.
-rw-r--r--doc/ScintillaHistory.html3
-rw-r--r--qt/ScintillaEdit/WidgetGen.py10
2 files changed, 12 insertions, 1 deletions
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html
index c03598f05..fad1797ce 100644
--- a/doc/ScintillaHistory.html
+++ b/doc/ScintillaHistory.html
@@ -470,6 +470,9 @@
On Windows, fix painting on an explicit HDC when first paint attempt abandoned.
</li>
<li>
+ Qt bindings in ScintillaEdit made to work on 64-bit Unix systems.
+ </li>
+ <li>
Easier access to printing on Qt with formatRange method.
</li>
<li>
diff --git a/qt/ScintillaEdit/WidgetGen.py b/qt/ScintillaEdit/WidgetGen.py
index b53fe988c..dc39dacab 100644
--- a/qt/ScintillaEdit/WidgetGen.py
+++ b/qt/ScintillaEdit/WidgetGen.py
@@ -71,9 +71,13 @@ def checkTypes(name, v):
def arguments(v, stringResult, options):
ret = ""
p1Type = cppAlias(v["Param1Type"])
+ if p1Type == "int":
+ p1Type = "uptr_t"
if p1Type:
ret = ret + p1Type + " " + normalisedName(v["Param1Name"], options)
p2Type = cppAlias(v["Param2Type"])
+ if p2Type == "int":
+ p2Type = "sptr_t"
if p2Type and not stringResult:
if p1Type:
ret = ret + ", "
@@ -101,7 +105,9 @@ def printHFile(f, options):
if feat in ["fun", "get", "set"]:
if checkTypes(name, v):
constDeclarator = " const" if feat == "get" else ""
- returnType = cppAlias(v["ReturnType"])
+ returnType = cppAlias(v["ReturnType"])
+ if returnType == "int":
+ returnType = "sptr_t"
stringResult = v["Param2Type"] == "stringresult"
if stringResult:
returnType = "QByteArray"
@@ -130,6 +136,8 @@ def printCPPFile(f, options):
constDeclarator = " const" if feat == "get" else ""
featureDefineName = "SCI_" + name.upper()
returnType = cppAlias(v["ReturnType"])
+ if returnType == "int":
+ returnType = "sptr_t"
stringResult = v["Param2Type"] == "stringresult"
if stringResult:
returnType = "QByteArray"