Answer the question
In order to leave comments, you need to log in
Is it possible to somehow manipulate pseudo-elements in JS?
Hello. I create html elements in a classic way:
let elem = document.createElement('p');
elem.innerHTML = 'text';
elem.className = 'class';
:before
that its content is equal to some text variable. How can this be implemented?
Answer the question
In order to leave comments, you need to log in
Qt has an abstraction over threads QtConcurrent . It has a run method . Where can you throw a method that you want to execute asynchronously. run will return you a QtFuture . Through it, we can find out what is happening with our thread (it has ended or is still running). A QtFuture can be passed to a QtFutureWatcher that has a finished signal that will fire when the function has completed its work.
The advantage of this approach is that Qt takes care of the hassle of creating and managing threads.
Use Windows messages via the SendMessage/PostMessage Api functions to communicate between threads.
stackoverflow.com/a/5734583
Only meaning?
It's all the same in JS, just add the necessary data to the beginning of the line...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question