Copy-paste from closed editor
Copy-paste from closed editor
I have Linux Mint 20.
I open my editor, copy from, paste to other place is ok.
I open my editor, copy from, close editor, paste to other place - no paste
It is for my editor, using Scintilla or Pascal Synedit.
But - if I open Gedit, copy from, close Gedit, is OK.
Is possible paste from my closed editor like Gedit?
I open my editor, copy from, paste to other place is ok.
I open my editor, copy from, close editor, paste to other place - no paste
It is for my editor, using Scintilla or Pascal Synedit.
But - if I open Gedit, copy from, close Gedit, is OK.
Is possible paste from my closed editor like Gedit?
Re: Copy-paste from closed editor
Do you use wxClipboard::Flush() in your code?
https://docs.wxwidgets.org/trunk/classw ... 33f291f932
https://docs.wxwidgets.org/trunk/classw ... 33f291f932
Re: Copy-paste from closed editor
I do :
But clipboard is cleared before destroy:, I must flush before delete notebook page.
Is problem: clibboard is cleared in wxModule::DoCleanUpModules ->
wxClipboardModule.OnExit(): wxDELETE(gs_clipboard);
Flush is only for application, not system?
Code: Select all
void MyFrame::OnCloseMain(wxCloseEvent& event)
{
if (CloseAll()) {
wxTheClipboard->Flush();
Destroy();
}
else
event.Veto();
}
Is problem: clibboard is cleared in wxModule::DoCleanUpModules ->
wxClipboardModule.OnExit(): wxDELETE(gs_clipboard);
Code: Select all
wxClipboard::~wxClipboard()
{
Clear();
gtk_widget_destroy( m_clipboardWidget ); <--------------------
gtk_widget_destroy( m_targetsWidget );
}
Re: Copy-paste from closed editor
Sorry, I do not use Linux myself, I am just aware of the method.
I assume you read the notes and did everything (i.e., have non-primary selection, checking the return value of Flush()).
Did you try the bundled clipboard sample and used File / Flush the Clipboard to see if it misbehaves as well on your system?
I assume you read the notes and did everything (i.e., have non-primary selection, checking the return value of Flush()).
Did you try the bundled clipboard sample and used File / Flush the Clipboard to see if it misbehaves as well on your system?
Re: Copy-paste from closed editor
Before closing I have text "Text from wx clipboard sample at Sat Sep 26 15:16:34 2020"
but after closing - no text.
I think it is Linux behaviour Other applications like Gedit (previously I badly check it) also not copied clipboard after closing.
Partially solution - editor will opened long time with single instance with IPC.
but after closing - no text.
I think it is Linux behaviour Other applications like Gedit (previously I badly check it) also not copied clipboard after closing.
Partially solution - editor will opened long time with single instance with IPC.
Re: Copy-paste from closed editor
Hi,
What is your version of wx?
What GTK version it is built against??
What WM are you using IGNOME, KDE, Mate, etc)?
Thank you.
What is your version of wx?
What GTK version it is built against??
What WM are you using IGNOME, KDE, Mate, etc)?
Thank you.
Re: Copy-paste from closed editor
I compiled wxWidgets 3.1.4 with configure:
../configure --enable-sockets --with-gtk=3 --enable-unicode --enable-debug --disable-monolithic --disable-shared
on Linux Mint 20
../configure --enable-sockets --with-gtk=3 --enable-unicode --enable-debug --disable-monolithic --disable-shared
on Linux Mint 20
Re: Copy-paste from closed editor
Hi,
Can you try clipbrd sample?
Also - Flush() call is for application - it stores the data inside the clipboard somewhere for later use.
Also try to build it with:
Thank you.
Can you try clipbrd sample?
Also - Flush() call is for application - it stores the data inside the clipboard somewhere for later use.
Also try to build it with:
Code: Select all
../configure --enable-debug ---with-gtk=3
Re: Copy-paste from closed editor
I have cinnamon. Other applications have the same problem, including gedit and gitk.
Re: Copy-paste from closed editor
Hi,
It might be native behavior then (native in terms of Window Manager).
Thank you.
It might be native behavior then (native in terms of Window Manager).
Thank you.