From 8cf888545b78221b3c27c8dc4601522332157b68 Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Wed, 7 Aug 2013 19:19:03 +1000 Subject: Bindings in ScintillaEdit made to work on 64-bit Unix systems. --- doc/ScintillaHistory.html | 3 +++ qt/ScintillaEdit/WidgetGen.py | 10 +++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) 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.
  • + Qt bindings in ScintillaEdit made to work on 64-bit Unix systems. +
  • +
  • Easier access to printing on Qt with formatRange method.
  • 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" -- cgit v1.2.3