XCompositeNameWindowPixmap / glXCreatePixmap

2022-03-21 Thread redhogxorg
Heyas!

I'm writing a compositing window manager that renders using opengl 
(https://redhog.github.io/InfiniteGlass/ ). To render windows, I'm using 
XCompositeNameWindowPixmap and glXCreatePixmap.

Calling glXCreatePixmap for each damage / content update is expensive. On some 
Xorg servers / display drivers it works to only call it one when calling 
XCompositeNameWindowPixmap, while on others hat means window content freezes. 
Specifically it doesn't seem to work under llvmpipe.

Setups where it works:

- A stock Ubuntu 18.04 on a physical machine with Mesa DRI Intel(R) UHD 
Graphics (CML GT2).

Setups where it doesn't work:

- Xephyr with llvmpipe (LLVM 10.0.0, 256 bits)
- A stock Ubuntu 18.04 under VirtualBox with llvmpipe (LLVM 12.0.0, 256 bits) 
(Not sure why this doesn't get hardware acceleration)

My question: What's the rule? Is there one? How do I detect whether I need to 
call it on every update or not?

Thanks in advance,
Egil

AW: Motif/Xt: Dynamically resize the visible item count of an XmList

2022-03-21 Thread Walter Harms
Hello,
for my understand of Widget programming it is a question
of the widget itself. It has some code inside to handle the resize event
and in this moment there seems no update of the visible_item_count.



Von: xorg  im Auftrag von Holger Sebert 

Gesendet: Freitag, 3. Dezember 2021 00:35:07
An: xorg@lists.x.org
Betreff: Motif/Xt: Dynamically resize the visible item count of an XmList

WARNUNG: Diese E-Mail kam von außerhalb der Organisation. Klicken Sie nicht auf 
Links oder öffnen Sie keine Anhänge, es sei denn, Sie kennen den/die 
Absender*in und wissen, dass der Inhalt sicher ist.


Hi,

I have an XmList (actually a ScrolledList) inside a RowColumn widget.

The visible item count of the list is configured at widget creation
time. When the RowColumn widget is resized, I would like to adapt that
visible item count to the new size of the parent widget.

Is there an easy way to do this?

What I have come up with so far in theroy is to do the following:
Listen to the resize event of the RowColumn widget, recompute the
visible line count in a callback and then set it explicitly using
XtSetValues(XmNvisibleItemCount).

Unfortunately, I have not found any callback resource in the RowColumn
widget.

How can I listen to resize events of a widget?

Best,
Holger