Qt Thin Client Application
-
Hello All,
We have a Qt thin client application and the entire UI is driven by HTML, JavaScript and CSS running on Linux platform. We have an issue with the display of caret cursor.
There is a small keyboard attached to the target, when we press keys, it prints the character associated with keycode and cursor comes and disappears .
To debug from this momentary cursor, we created a test html with no javascript/css in it.
Test html pasted below:
<html><head>
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript">
function init(){
}
</script>
</head>
<BODY onload="init()" style="overflow: hidden;color: black; background-color: #000000" oncontextmenu="DDU_DAS_KeyManager_OnPage_ContextMenu()" draggable="false" ondragstart="return false;">
<INPUT type="text" ID="GfxInputDas7657338" style="text-decoration: normal;font-weight: normal;font-style: normal;text-align: left;font-family: Arial;font-size: 10pt;color: #000000;z-index: 1;position: absolute;top: 95;left: 87;width: 348;height: 107;background-color: #ffffff;opacity: 1;border: 1px solid #00ff00;visibility: visible;resize: none; display: block" autofocus></INPUT>
</BODY></html>Request inputs/pointers to get the caret cursor display,
Thanks,
nkr -
What web engine does the client use? Which version?
-
@radhank said in Qt Thin Client Application:
Version 5
That's very vague. Version 5.0.0? Version 5.6.3? Something else?
There is a small keyboard attached to the target, when we press keys, it prints the character associated with keycode and cursor comes and disappears .
To debug from this momentary cursor, we created a test html with no javascript/css in it.
Test html pasted below:
<html><head>
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript">
function init(){
}
</script>
</head>
<BODY onload="init()" style="overflow: hidden;color: black; background-color: #000000" oncontextmenu="DDU_DAS_KeyManager_OnPage_ContextMenu()" draggable="false" ondragstart="return false;">
<INPUT type="text" ID="GfxInputDas7657338" style="text-decoration: normal;font-weight: normal;font-style: normal;text-align: left;font-family: Arial;font-size: 10pt;color: #000000;z-index: 1;position: absolute;top: 95;left: 87;width: 348;height: 107;background-color: #ffffff;opacity: 1;border: 1px solid #00ff00;visibility: visible;resize: none; display: block" autofocus></INPUT>
</BODY></html>It works fine for me when I use Qt WebEngine on Qt 5.13.1 (Click here to see)
-
Sorry for not being precise. its 5.3.2
You are right. Test application does not have any issue. we could see the cursor.
Am quite new to X windows as well as Qt. we have a display manager, which manages displaying these clients. We create a qt window and we share the window ID with the display manager through a FIFO and set this property using XchangeProperty.
Sample code below:
display = XOpenDisplay(NULL);
Window qtWindow= MainWindow->effectiveWinId();Atom propertyName = XInternAtom(display, USER_DATA_ATOM_NAME, 0); Atom propertyType = XInternAtom(display, USER_DATA_ATOM_TYPE, 0); ret = XChangeProperty(display, qtWindow, propertyName, propertyType, 32, PropModeReplace, (unsigned char*)& UserData, // User data contains the (sizeof(DESK_TS_phUserData)/sizeof(char*))); // window id, application // name ret = XSync(display, False); XCloseDisplay(display);
Its very clear from our test yesterday that this interface is causing trouble.
We want to understand though we can see the pages, why the caret cursor is missing.
Is there anything we are missing?Thanks,
-
Sorry for not being precise. its 5.3.2
You are right. Test application does not have any issue. we could see the cursor.
Am quite new to X windows as well as Qt. we have a display manager, which manages displaying these clients. We create a qt window and we share the window ID with the display manager through a FIFO and set this property using XchangeProperty.
Sample code below:
display = XOpenDisplay(NULL);
Window qtWindow= MainWindow->effectiveWinId();Atom propertyName = XInternAtom(display, USER_DATA_ATOM_NAME, 0); Atom propertyType = XInternAtom(display, USER_DATA_ATOM_TYPE, 0); ret = XChangeProperty(display, qtWindow, propertyName, propertyType, 32, PropModeReplace, (unsigned char*)& UserData, // User data contains the (sizeof(DESK_TS_phUserData)/sizeof(char*))); // window id, application // name ret = XSync(display, False); XCloseDisplay(display);
Its very clear from our test yesterday that this interface is causing trouble.
We want to understand though we can see the pages, why the caret cursor is missing.
Is there anything we are missing?Thanks,
@radhank said in Qt Thin Client Application:
Sorry for not being precise. its 5.3.2
That version reached end-of-life in 2016. Would you consider upgrading?
You are right. Test application does not have any issue. we could see the cursor.
Am quite new to X windows as well as Qt. we have a display manager, which manages displaying these clients. We create a qt window and we share the window ID with the display manager through a FIFO and set this property using XchangeProperty....
We want to understand though we can see the pages, why the caret cursor is missing.
I don't know the answer, sorry.
- Is the caret cursor missing if you use XChangeProperty on a simple widget like a QLineEdit?
- Is the caret cursor missing if you use XChangeProperty on a non-Qt application?