Skip to content

Commit

Permalink
ver 1.2.9 - TLazAccessibleObject accessibility
Browse files Browse the repository at this point in the history
  • Loading branch information
David Bannon committed Apr 6, 2021
1 parent 2e64251 commit 5121bab
Show file tree
Hide file tree
Showing 13 changed files with 664 additions and 8 deletions.
18 changes: 14 additions & 4 deletions cbindings/Qt5Pas.pro
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@



# Binding Release against Qt5 5.6 LTS release.
# Binding Release Version 2.6 against Qt5 5.6 LTS release.
# WebKit widgets are disabled until webenginewidgets are implemented.

VERSION = 1.2.8
VERSION = 1.2.9

QT += gui network printsupport
TARGET = Qt5Pas
Expand All @@ -33,6 +33,11 @@ is64 = $$find(QMAKE_HOST.arch, ".*64")
QMAKE_CXXFLAGS += -mstackrealign -mincoming-stack-boundary=2
}

haiku:isEmpty(is64) {
message("Added stack alignment options to CXXFLAGS in support of SSE i386 on Haiku")
QMAKE_CXXFLAGS += -mstackrealign -mincoming-stack-boundary=2
}

!equals(QT_MAJOR_VERSION,5)|!equals(QT_MINOR_VERSION,6) {
message("Note: This binding version was generated for Qt 5.6.1. Current Qt is" $$QT_VERSION)
message("Qt documents binary compatibility in each Version Change Note: http://qt.nokia.com/developer/changes")
Expand Down Expand Up @@ -73,8 +78,7 @@ CONFIG -= warn_on
CONFIG -= create_prl
CONFIG -= link_prl

CONFIG -= release
CONFIG += debug
CONFIG += release
CONFIG += dll
CONFIG += warn_off

Expand Down Expand Up @@ -224,6 +228,9 @@ HEADERS += \
qabstractscrollarea_c.h \
qabstractscrollarea_hook.h \
qlclabstractscrollarea_c.h \
qaccessible_c.h \
qaccessiblewidget_c.h \
qlclaccessiblewidget_c.h \
qabstractslider_c.h \
qabstractslider_hook.h \
qscrollbar_c.h \
Expand Down Expand Up @@ -561,6 +568,9 @@ SOURCES += \
qstackedwidget_c.cpp \
qabstractscrollarea_c.cpp \
qlclabstractscrollarea_c.cpp \
qaccessible_c.cpp \
qaccessiblewidget_c.cpp \
qlclaccessiblewidget_c.cpp \
qabstractslider_c.cpp \
qscrollbar_c.cpp \
qmenu_c.cpp \
Expand Down
6 changes: 6 additions & 0 deletions cbindings/package/changelog.libqt5pas
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
libqt5pas (1.2.9) unstable; urgency=medium

* TLazAccessibleObject accessinility functionality for Qt5 widgetsets

-- David Bannon <[email protected]> Tue, 06 Apr 2021 18:29:02 +1100

libqt5pas (1.2.8) unstable; urgency=medium

* Calling this version 1.2.8
Expand Down
4 changes: 2 additions & 2 deletions cbindings/package/deb-package
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function WriteControl () {
echo "Depends: $PRODUCT$MAJORVER (>= $MINORVER)" >> BUILD/DEBIAN/control
echo "Section: libdevel" >> BUILD/DEBIAN/control
echo "Description: Development files for Qt5Pas" >> BUILD/DEBIAN/control
echo " Provides interface for Pascal applications tp Qt6 C++ libs" >> BUILD/DEBIAN/control
echo " Provides interface for Pascal applications to Qt5 C++ libs" >> BUILD/DEBIAN/control
else
echo "Installed-Size: 3314" >> BUILD/DEBIAN/control
echo "Depends: libc6 (>= 2.14), libgcc1 (>= 1:3.0), libqt5core5a (>= 5.7.0), libqt5gui5 (>= 5.6.0~beta) | libqt5gui5-gles (>= 5.6.0~beta), libqt5network5 (>= 5.6.0~beta), libqt5printsupport5 (>= 5.2.0), libqt5widgets5 (>= 5.6.0~beta), libqt5x11extras5 (>= 5.6.0), libstdc++6 (>= 5)" >> BUILD/DEBIAN/control
Expand Down Expand Up @@ -115,7 +115,7 @@ DebianPackageDev

ls -ltr

echo " === OK, now make the rpms with sudo bash ./rpm-package <enter> ==="
echo " === OK, now make the rpms with fakeroot bash ./rpm-package.bash <enter> ==="



2 changes: 1 addition & 1 deletion cbindings/qt5.pas
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

unit qt5;

{ Version : 2.6Beta , no, 2.8 for clarity }
{ Version : 2.6Beta }

{$mode objfpc}{$H+}

Expand Down
5 changes: 5 additions & 0 deletions cbindings/src/chandles.h
Original file line number Diff line number Diff line change
Expand Up @@ -519,4 +519,9 @@ typedef struct QSplitterHandle__ { PTRINT dummy; } *QSplitterHandleH;
typedef struct QCalendarWidget__ { PTRINT dummy; } *QCalendarWidgetH;
typedef struct QFileSystemWatcher_hook__ { PTRINT dummy; } *QFileSystemWatcher_hookH;
typedef struct QInputMethodQueryEvent__ { PTRINT dummy; } *QInputMethodQueryEventH;

typedef struct QAccessibleEvent__ { PTRINT dummy; } *QAccessibleEventH;
typedef struct QAccessibleInterface__ { PTRINT dummy; } *QAccessibleInterfaceH;
typedef struct QAccessibleWidget__ { PTRINT dummy; } *QAccessibleWidgetH;
typedef struct QLCLAccessibleWidget__ { PTRINT dummy; } *QLCLAccessibleWidgetH;
#endif
63 changes: 63 additions & 0 deletions cbindings/src/qaccessible_c.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
//******************************************************************************
// Copyright (c) 2005-2013 by Jan Van hijfte
//
// See the included file COPYING.TXT for details about the copyright.
//
// 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.
//******************************************************************************


#include "qaccessible_c.h"

QAccessibleInterfaceH QAccessible_accessibleInterface(QAccessibleId uniqueId)
{
return (QAccessibleInterfaceH) QAccessible::accessibleInterface(uniqueId);
}

void QAccessible_deleteAccessibleInterface(QAccessibleId uniqueId)
{
QAccessible::deleteAccessibleInterface(uniqueId);
}

void QAccessible_installFactory(InterfaceFactory factory)
{
QAccessible::installFactory(factory);
}

bool QAccessible_isActive()
{
return QAccessible::isActive();
}

QAccessibleInterfaceH QAccessible_queryAccessibleInterface(QObjectH object_)
{
return (QAccessibleInterfaceH) QAccessible::queryAccessibleInterface((QObject *)object_);
}

QAccessibleId QAccessible_registerAccessibleInterface(QAccessibleInterfaceH iface)
{
return (QAccessibleId) QAccessible::registerAccessibleInterface((QAccessibleInterface *)iface);
}

void QAccessible_removeFactory(InterfaceFactory factory)
{
QAccessible::removeFactory(factory);
}

void QAccessible_setRootObject(QObjectH object_)
{
QAccessible::setRootObject((QObject *)object_);
}

QAccessibleId QAccessible_uniqueId(QAccessibleInterfaceH iface)
{
return (QAccessibleId) QAccessible::uniqueId((QAccessibleInterface *)iface);
}

void QAccessible_updateAccessibility(QAccessibleEventH event)
{
QAccessible::updateAccessibility((QAccessibleEvent *)event);
}

31 changes: 31 additions & 0 deletions cbindings/src/qaccessible_c.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
//******************************************************************************
// Copyright (c) 2005-2013 by Jan Van hijfte
//
// See the included file COPYING.TXT for details about the copyright.
//
// 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.
//******************************************************************************


#ifndef QACCESSIBLE_C_H
#define QACCESSIBLE_C_H

#include <QtWidgets>
#include "pascalbind.h"

typedef unsigned QAccessibleId;
typedef QAccessibleInterface*(*InterfaceFactory)(const QString &key, QObject*);

C_EXPORT QAccessibleInterfaceH QAccessible_accessibleInterface(QAccessibleId uniqueId);
C_EXPORT void QAccessible_deleteAccessibleInterface(QAccessibleId uniqueId);
C_EXPORT void QAccessible_installFactory(InterfaceFactory factory);
C_EXPORT bool QAccessible_isActive();
C_EXPORT QAccessibleInterfaceH QAccessible_queryAccessibleInterface(QObjectH object_);
C_EXPORT QAccessibleId QAccessible_registerAccessibleInterface(QAccessibleInterfaceH iface);
C_EXPORT void QAccessible_removeFactory(InterfaceFactory factory);
C_EXPORT void QAccessible_setRootObject(QObjectH object_);
C_EXPORT QAccessibleId QAccessible_uniqueId(QAccessibleInterfaceH iface);
C_EXPORT void QAccessible_updateAccessibility(QAccessibleEvent event);
#endif
92 changes: 92 additions & 0 deletions cbindings/src/qaccessiblewidget_c.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
//******************************************************************************
// Copyright (c) 2005-2013 by Jan Van hijfte
//
// See the included file COPYING.TXT for details about the copyright.
//
// 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.
//******************************************************************************


#include "qaccessiblewidget_c.h"



QAccessibleWidgetH QAccessibleWidget_Create(QWidgetH o, QAccessible::Role r, PWideString name)
{
QString t_name;
copyPWideStringToQString(name, t_name);
return (QAccessibleWidgetH) new QAccessibleWidget((QWidget*)o, r, t_name);
}

bool QAccessibleWidget_isValid(QAccessibleWidgetH handle)
{
return (bool) ((QAccessibleWidget *)handle)->isValid();
}

QWindowH QAccessibleWidget_window(QAccessibleWidgetH handle)
{
return (QWindowH) ((QAccessibleWidget *)handle)->window();
}

int QAccessibleWidget_childCount(QAccessibleWidgetH handle)
{
return (int) ((QAccessibleWidget *)handle)->childCount();
}

int QAccessibleWidget_indexOfChild(QAccessibleWidgetH handle, const QAccessibleInterfaceH child)
{
return (int) ((QAccessibleWidget *)handle)->indexOfChild((QAccessibleInterface*)child);
}

QAccessibleInterfaceH QAccessibleWidget_focusChild(QAccessibleWidgetH handle)
{
return (QAccessibleInterfaceH) ((QAccessibleWidget *)handle)->focusChild();
}

void QAccessibleWidget_rect(QAccessibleWidgetH handle, PRect retval)
{
QRect t_retval;
t_retval = ((QAccessibleWidget *)handle)->rect();
copyQRectToPRect(t_retval, retval);
}

QAccessibleInterfaceH QAccessibleWidget_parent(QAccessibleWidgetH handle)
{
return (QAccessibleInterfaceH) ((QAccessibleWidget *)handle)->parent();
}

QAccessibleInterfaceH QAccessibleWidget_child(QAccessibleWidgetH handle, int index)
{
return (QAccessibleInterfaceH) ((QAccessibleWidget *)handle)->child(index);
}

void QAccessibleWidget_text(QAccessibleWidgetH handle, PWideString retval, QAccessible::Text t)
{
QString t_retval;
t_retval = ((QAccessibleWidget *)handle)->text(t);
copyQStringToPWideString(t_retval, retval);
}

QAccessible::Role QAccessibleWidget_role(QAccessibleWidgetH handle)
{
return (QAccessible::Role) ((QAccessibleWidget *)handle)->role();
}

QAccessible::State QAccessibleWidget_state(QAccessibleWidgetH handle)
{
return (QAccessible::State) ((QAccessibleWidget *)handle)->state();
}

void QAccessibleWidget_actionNames(QAccessibleWidgetH handle, QStringListH retval)
{
*(QStringList *)retval = ((QAccessibleWidget *)handle)->actionNames();
}

void QAccessibleWidget_doAction(QAccessibleWidgetH handle, PWideString actionName)
{
QString t_actionName;
copyPWideStringToQString(actionName, t_actionName);
((QAccessibleWidget *)handle)->doAction(t_actionName);
}
41 changes: 41 additions & 0 deletions cbindings/src/qaccessiblewidget_c.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
//******************************************************************************
// Copyright (c) 2005-2013 by Jan Van hijfte
//
// See the included file COPYING.TXT for details about the copyright.
//
// 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.
//******************************************************************************


#ifndef QACCESSIBLEWIDGET_C_H
#define QACCESSIBLEWIDGET_C_H

// QAccessible::Role
// -
// QAccessible::State
// -
// QAccessible::Text
// -

#include <QtWidgets>
#include "pascalbind.h"

C_EXPORT QAccessibleWidgetH QAccessibleWidget_Create(QWidgetH o, QAccessible::Role r, PWideString name);
C_EXPORT bool QAccessibleWidget_isValid(QAccessibleWidgetH handle);
C_EXPORT QWindowH QAccessibleWidget_window(QAccessibleWidgetH handle);
C_EXPORT int QAccessibleWidget_childCount(QAccessibleWidgetH handle);
C_EXPORT int QAccessibleWidget_indexOfChild(QAccessibleWidgetH handle, const QAccessibleInterfaceH child);
C_EXPORT QAccessibleInterfaceH QAccessibleWidget_focusChild(QAccessibleWidgetH handle);
C_EXPORT void QAccessibleWidget_rect(QAccessibleWidgetH handle, PRect retval);
C_EXPORT QAccessibleInterfaceH QAccessibleWidget_parent(QAccessibleWidgetH handle);
C_EXPORT QAccessibleInterfaceH QAccessibleWidget_child(QAccessibleWidgetH handle, int index);
C_EXPORT void QAccessibleWidget_text(QAccessibleWidgetH handle, PWideString retval, QAccessible::Text t);
C_EXPORT QAccessible::Role QAccessibleWidget_role(QAccessibleWidgetH handle);
C_EXPORT QAccessible::State QAccessibleWidget_state(QAccessibleWidgetH handle);
C_EXPORT void QAccessibleWidget_actionNames(QAccessibleWidgetH handle, QStringListH retval);
C_EXPORT void QAccessibleWidget_doAction(QAccessibleWidgetH handle, PWideString actionName);


#endif
Loading

0 comments on commit 5121bab

Please sign in to comment.