View Single Post
Old 08-02-2023, 07:42 PM   #5
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,884
Karma: 6120478
Join Date: Nov 2009
Device: many
Update:

It appears that QPlainTextEdit (CodeView) seems to default to setAcceptDrops(true) instead of the previously default false.

I literally had to add a setAcceptDrops(false); to the CodeViewEditor constructor to disable it.

Strange ....


Quote:
From the Qt 6.5 and Qt 5.15 docs:

acceptDrops : bool

This property holds whether drop events are enabled for this widget

Setting this property to true announces to the system that this widget may be able to accept drop events.

If the widget is the desktop (windowType() == Qt::Desktop), this may fail if another application is using the desktop; you can call acceptDrops() to test if this occurs.

Warning: Do not modify this property in a drag and drop event handler.
By default, this property is false.

Access functions:

bool acceptDrops() const
void setAcceptDrops(bool on)
See also Drag and Drop.

Kevin

Last edited by DiapDealer; 08-02-2023 at 07:59 PM.
KevinH is offline   Reply With Quote