When I tried to select some string on serial monitor the cursor arrow is not the position selected, but the middle of the cursor (line below).
It is very strange.
I am running the Arduino IDE 2.0.0-rc9.1 on Windows 10 Pro
Hi @CamargoF . Thanks so much for bringing this to our attention. I have submitted a formal report to the Arduino IDE developers on your behalf:
opened 03:21AM - 05 Aug 22 UTC
closed 06:40AM - 27 Sep 22 UTC
conclusion: resolved
topic: code
type: imperfection
topic: serial monitor
### Describe the problem
It is often necessary or useful to select and copy t… ext from the board output printed in the **Serial Monitor** view.
Due to the nature of this element, selection of specific text is always done via a click and drag action. Standard behavior is that the selection should be initiated from the character at the position under the tip of the mouse pointer.
🐛 The selection is initialized from a position lower than the tip of the mouse pointer.
### To reproduce
#### Equipment
- Any Arduino board that produces a port
#### Steps
1. Create a sketch that produces serial output:
```cpp
void setup() {
Serial.begin(9600);
}
void loop() {
Serial.println("hello");
delay(1000);
}
```
1. Upload the sketch to your Arduino board.
1. Open the **Serial Monitor** view.
1. Select "**9600**" from the baud rate menu at the top right corner of the **Serial Monitor** view.
**ⓘ** The issue is not specific to this baud rate, it only needs to match whatever value set in the sketch if a board without native USB capabilities is in use.
1. Deselect the "**Toggle Autoscroll**" icon on the bottom panel toolbar.
**ⓘ** The issue occurs even with autoscroll enabled, but it will be more difficult to be certain of the location of the mouse pointer relative to the text if it is scrolling.
1. Place the mouse pointer at or below the vertical center of a line of text where there are additional lines of text below.
1. Click and drag downward.
🐛 The selection starts from the line below the vertical position of the mouse pointer:

### Expected behavior
Selection is made according to the location of the tip of the mouse pointer.
### Arduino IDE version
2.0.0-rc9.1-snapshot-0b33b51
### Operating system
Windows
### Operating system version
10
### Additional context
I bisected the introduction of the bug to aba9db6 / https://github.com/arduino/arduino-ide/pull/943
---
https://github.com/arduino/arduino-ide/issues/972 was also introduced at aba9db6 and feels similar in that it is related to vertical position. So this issue and that one may be two distinct symptoms of the same root defect.
---
Related in subject matter (but not in cause):
- https://github.com/arduino/arduino-ide/issues/247
- https://github.com/arduino/arduino-ide/issues/1081
- https://github.com/arduino/arduino-ide/issues/812
- https://github.com/arduino/arduino-ide/issues/289
- https://github.com/arduino/arduino-ide/issues/105
---
Originally reported at https://forum.arduino.cc/t/selecting-text-on-monitor-screen/1019343
### Issue checklist
- [X] I searched for previous reports in [the issue tracker](https://github.com/arduino/arduino-ide/issues?q=)
- [X] I verified the problem still occurs when using the latest [nightly build](https://github.com/arduino/arduino-ide#nightly-builds)
- [X] My report contains all necessary details
If you have a GitHub account, you can subscribe to that issue to get notifications of any new developments related to this subject.
1 Like
system
Closed
February 1, 2023, 3:21am
3
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.