|
Member 14968771 wrote: Your analogy is plausible, however, it does not explain how clicking on the text highlights it – if it is "gone" / does not exist per your explanation. It does not exist in your application (well, your application may still have the original, from which a copy was sent to xterm, but that is a different object). But xterm saves in its own buffer the output it receives from the application. It uses the contents of the buffer to redraw the window, say, if you resize it, or scroll the text up and down.
This text buffer belongs to xterm. It is not accessible to your application. The highlighting is done in this buffer, by xterm.
All you input and output goes through xterm (as long as your focus is in the xterm window). xterm knows where you click your mouse, and knows the size of character cells in its window (they are all the same, at least in classic xterm). Calculating from the mouse coordinates which character cell was clicked is trivial. (If you use variable-width font, it is just semi-trivial.) xterm starts at from this character and looks at the preceding and following characters in its text buffer. As long as they are 'word characters', it adds highlight to it and searches forward, but stops on whitespace, punctuation etc.
If you could monitor the connection between xterm and your application when you mark the word, you would see none. The marking is something xterm does for itself, alone.
I haven't been working with xterm for a number of years, and don't remember all the details, but like most *nix-born applications, it has a ton of options. I guess that you can tell xterm to give you all the raw input - certainly from the keyboard, so that your application can interpret copy (mark) and paste keystrokes, but maybe even mouse input. Your problem is that xterm manages its own scrolling, word wrapping etc. and your application cannot know where it has placed the output text you gave it. So even if you get the mouse click position, you don't have the information to know which word the cursor was pointing at.
If I understand your need correctly (and you do not want to give your application its own tailor made X-based user interface), the simple but somewhat pedal driven way to do it is to open a text editor with a new empty file (or one where you want to add another log record), mark the text in your xterm window, and then past them into the file in the text editor. There are multiple ways to mark text in xterm - single, double, triple click, mouse drag etc.
By *nix conventions marked text is put into the copy&paste buffer. I believe (not 100% sure) that even the Windows version of xterm is *nix like; it doesn't require any ctrl-C to copy the text. Pasting into the text editor file (or any other *nix style application) is usually done with the middle mouse button (or left, if you have no middle). If you run in Windows environment, and the text editor is a Windows application, be prepared to use ctrl-V or some menu selection to paste the text.
And again: If you monitor the communication between your application and xterm, there is no trace of the copy&paste into the text editor file. The copying is a private matter between xterm and the editor.
If you have as a requirement that your application must be aware of the copy&paste, you have to abandon xterm and straight command line output, and give your application its own X-based GUI. That will complicate it significantly. If you go for that solution, do not attempt to program at the X.11 level - that is like 'GUI assembly coding'. Find some X.11 based library / GUI platform. I haven't made a *nix GUI since Motif was the standard library, but most likely, today it has competition from about 42 alternative libraries, all open source, free for you to study the source code 
|
|
|
|
|
"Selecting" is an illusion; screen coordinates interpreted by the OS, then the framework (which gives it context), and lastly the application.
There's nothing to "grab" except pixels unless you have a hook into the framework or app. The "device" knows nothing of the software that drives it; and that's why you're in the wrong forum, again.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
That is just a feature of the Window that displays the text, and most Window types have that feature. So unless the window allows you to copy/cut the highlighted text you are out of luck.
|
|
|
|
|
My current , working multiOS system is doing as good as expected , however, periodically I get a system crash with error messages indicating RAID timeout.
The "problem " is - I have only ONE functioning RAID 5 - according to "mdadm".
The "failing" device is "md10" which , from experience, does not mean anything - the md devices numbering is done by Ubuntu/ Linux OS and it is unpredictable.
BUT I know "md10" does not exist....mdadm said so.
The question - how do I delete / tell Linux to delete/ no use , non used RAID "md10" ?
|
|
|
|
|
I have a grub menu continually having an option of OS which is " missing the kernel " .
I have removed the offending OS partition and run "update-grub".
The "missing kernel OS" did not get detected , however , after reboot
it is still in grub menu.
|
|
|
|
|
Insisting your Linux / Bluetooth issues are "hardware and device" issues ... because that's "your choice". You think that will help your case?
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
|
Is there a real Bluetooth guru here who can help / lead me to an answer ?
After many trips to RTFM I still cannot find how to disable current agent .
I actually turned Bluetooth off in my Linux OS and still getting this
q5@q5-desktop:~$ bluetoothctl
Agent registered
[CHG] Controller 00:15:83:15:A2:CB Class: 0x00000000
[CHG] Controller 00:15:83:15:A2:CB Powered: no
[CHG] Controller 00:15:83:15:A2:CB Discovering: no
[bluetooth]# quit
q5@q5-desktop:~$ bluetoothctl
Agent registered
[bluetooth]#
Here is what quit / exit do
quit Quit program
exit Quit program
I really need a "first usage of the command response" - when the agent is not registered.
( In case somebody have the stupid idea -
GO ask somewhere else - I AM ASKING HERE AND THAT IS MY CHOICE - so deal with it )
|
|
|
|
|
You've chosen the wrong site for your linux support questions, so YOU deal with it!
|
|
|
|
|
Hello, I am creating a program that will find and identify all equipment on a network. I need to find all computers, printers, thumdrives, cams, external harddrives, bar coder/scanners, ... It might be easier to state what I do not need. I do not need keyboards, mice, hubs, usb hubs, etc.
I prefer VB.net since that is what we use in the office.
modified 25-Aug-22 1:49am.
|
|
|
|
|
...and the actual problem you're having with this is...?
|
|
|
|
|
Harry, As desirable as a solution to your issue may be, you have listed devices that are typically on different "networks", some (e.g. USB) that require access through a likely opaque bridge (PC). Not an easy task.
|
|
|
|
|
Watch who you're replying to.
I don't need the notification that you posted anything to me, but the OP does.
Also, I already know what you're talking about.
|
|
|
|
|
Impossible. Cut your losses and go home.
|
|
|
|
|
OK ... go for it. This is not where we go: "I couldn't help overhearing ..."
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
After clean install - from EFI ISO - my setup shows another "Ubuntu" boot resource. Is there a way I can physically determine on which device this file reside? ( in system setup ?)
I still do not know the actual name of these "Ubuntu" files. ( Any real reference to in which RTFM to find this in would be appreciated)
Somewhat related issue.
If I install the new , clean Ubuntu onto a USB stick ( 32GB ) , the "update-grub" will not detect the rest of the multiboot OS. It is officially disabled. However - the system setup will show yet another "Ubuntu" boot resource. ( Yes I can guess which file this new "Ubuntu" is on the small USB stick )
|
|
|
|
|
|
How were the electronical hardware settings on a plane stored before the invention of solid state hard drives? To my mind a plane`s auto pilot is a rather complex piece of software with a lot of data to be kept somewhere when the plane computer is off. Also there are plenty of other electronics that need the default settings saved somewhere when the power is off.
A conventional hard drive must have been rather unpractical on a moving vehicle.
Also the lack of storage makes you understand how rudimentary the aero plane electronical devices were in WW2 days and even a few decades after that.
[edit]
I think my question is broader that the scope of aero plane electronics. How are the default settings in (general purpose) electronics being saved? One of my guesses is that the logic is hard coded into the circuitry. For instance the shape of a number on an old numerical display is not saved digitally (as dots making the shape) but rather each of the 7 segments making the digit has a corresponding electronical component that kicks in when required. It`s really difficult to figure out how electronics work when you`re born with a notebook in your lap, somehow understand how the software works but preserve a very vague understanding of what`s under the notebook casing.
modified 20-Aug-22 10:16am.
|
|
|
|
|
I would think it's mostly analog; which in my mind is simpler than dealing with digital feedback information. Altitude, velocity, direction, orientation, ...; action - reaction.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
thanks.
your second statement is slightly disorienting. You`re talking about digital "feedback" which is similar, on a superficial level, with force feedback. If my understanding is correct planes do have force feedback on the control column.
|
|
|
|
|
Edit
Question #1
On initial power -up I get black screen with centered hardware vendor logo and several lines of text - in lower right corner - giving info about how to access system setup using function keys.
what application posts these lines of text ?
Question #2
The above "lines of text" go away after a time
Where is this timeout set ?
Question #3
On multi OS system SINGLE message about "mdxx" timeout is causing total system crash...
This particular mdxx device is unused , non working leftover from RAID 5...
There is NO question for this item.... any guesses are irrelevant, do not bother.
Question #4
The grub menu OS option is labeled "21,10" - it does not boot...
The "advanced" option - under same main menu boots with message
"welcome to 22.04".
The "advanced " options are labeled as "generic...xxxx " , not as versions as the
main option is.
The question is
what application builds the "grub" menu , where is the file which build this
and why version and generic differ?
I would like to connect with somebody who
uses Linux / Ubuntu in multi operating system confirmation .
Multi OS scattered on multi hardware devices...
A real user, no RTFM, u-tube, post this somewhere else etc.
I have been trying to figure out how such system boots –
specially what are the parts of the boot process.
I know there is a hardware system setup – UEFI
It has setting for “boot process”….
I know under normal conditions I get a “menu screen”
– presumably build by “grub” (residing where ?)
I know and have observed “update “ to “update grub”…
When I change “grub” defaults I am nagged by coders to
“update grub manually “
That is all nice but I like to be sure .
This is for learning purposes , not to fix or elaborate on questions.
There are no questions / problems to fix in this post.
Please no " I know nothing about Ubuntu , my Windoze XYZ works great... "
Thanks
Cheers
modified 17-Aug-22 21:30pm.
|
|
|
|
|
Member 14968771 wrote: A real user, no RTFM, u-tube, post this somewhere else etc.
Member 14968771 wrote: Please no " I know nothing about Ubuntu , my Windoze XYZ works great... "
How about you stop giving orders and just ask the questions.
Multiboot2 Specification version 2.0[^].
|
|
|
|
|
But what you are giving him is an "RTFM" - which is what he was explicitly not asking for!
He was asking for "A real user". A person that could act as his personal advisor, guru, servant, code generator or whatever - one that can fix his problems right away without bothering him with lots of stuff that only remotely or indirectly relates to what he is struggling with. You gave him a text, not a person.
So he is right if he claims that your answer is exactly what he stated that he did not want.
|
|
|
|
|
Why do you think I did it? 
|
|
|
|
|
I suspect "real users" read the manual at some point. I don't see any evidence that the OP did any reading. What does that say.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|