Comments (21)
Here area couple of screen capture showing the difference (zoomed 200%):
The system setting for the mouse cursor is just Small to Large. The panel height is 40 pixels, so the system mouse cursor is +/- 24. In LC it is maybe 16 pixels.
from librecad.
I changed line 69 in /LibreCAD-master/librecad/src/ui/qg_graphicview.cpp from
#if (defined (Q_OS_WIN32) || defined (Q_OS_WIN64))
to
#if (defined (Q_OS_WIN32) || defined (Q_OS_WIN64) || defined (Q_OS_LINUX) || defined (Q_OS_MACOS))
...and it seemed to do the trick (in a Debian VM at various resolutions from 1920x1080 to 3840x2160) and it remained at an appropriate size (if not larger in LC than the system cursor). I compared the native LC I compiled to the most recent appImage.
(Can you try it on your Windows PC?)
from librecad.
The three installation packages (Win64, appImage, dmg) would be addressed with
#if (defined (Q_OS_WIN64) || defined (Q_OS_LINUX) || defined (Q_OS_MACOS))
while remaining OSes would default to the defined CURSOR_SIZE.
I haven't seen any comments about macOS and I don't have access to Mac, so Im guessing it woiuld be the same problem on a Mac with a hi-res screen with the way it is currently defined...
from librecad.
Could someone help me confirm this issue?
I am using standard 1920x1080 screens here.
from librecad.
I did some poking around the source and I found the following in /LibreCAD-master/librecad/src/ui/qg_graphicview.cpp:
#if (defined (Q_OS_WIN32) || defined (Q_OS_WIN64))
#define CURSOR_SIZE 16
#else
#define CURSOR_SIZE 15
#endif
Am I correct in my thinking that in Windows the system cursor size is used, but in Linux and MacOS it would be fixed at 15 pixels? The Qt documentation lists, among a whole bunch of additionsl OSes, "Q_OS_LINUX" and "Q_OS_MACOS"
from librecad.
Cursors are controlled by Qt. We can set the pixel sizes, but for cursors (and other GUI items, except drawing in coordinated), the pixels are in device independent units for Qt, meaning Qt will scale them by a factor, if high dpi device is detected.
So, the size 16 may mean 32 actual pixels on high dpi.
It helps to play with this value still
from librecad.
It means for all systems we are targeting
from librecad.
I will test on Mac.
Could you create a PR?
from librecad.
I don't have a full develoipment environment set up so I cannot create a PR right now. It is a minor edit:
Change line 69 in /LibreCAD-master/librecad/src/ui/qg_graphicview.cpp from
#if (defined (Q_OS_WIN32) || defined (Q_OS_WIN64))
to
#if (defined (Q_OS_WIN64) || defined (Q_OS_LINUX) || defined (Q_OS_MACOS))
Does LC still need a Win32 variant?
from librecad.
Could you test this fix?
32bit windows is gone in the new development branch. However, we should be careful when removing win32 definitions in source code, because win32 is also used for 64bit windows
from librecad.
Here are a few comparisons (g_cursorSize=32):
previous version of appimage @3840x2160
Actual cursor ~20 pixels
compiled with latest commit at @3840x2160
Actual cursor ~54 pixels
previous version of appimage @2560x1080
Actual cursor ~40 pixels
"w/commit at @2560x1080
Actual cursor ~54 pixels
And just because I was curious (g_cursorSize=16):
Actual cursor ~58 pixels
(These screen captures are cropped and enlarged. At native resolution the cursors are much smaller.)
It seems the g_cursorSize is a default but overridden by system(?) Or a max / min? What ever the case, much better!
from librecad.
The latest appImage (LibreCAD-latest-1-g3112c123.AppImage) fails with ... error while loading shared libraries: libQt6Svg.so.6: cannot open shared object file: No such file or directory
from librecad.
The specified 32 is treated as device independent pixels, so ended up roughly the same size on different physical pixel pitches
from librecad.
I just tested the latest master branch AppImage: 581dc21
The AppImage works for me, and there's only minor changes from 3112c12
from librecad.
Good news and bad news. I downloaded the latest appImage and yes, it launches. The bad news is that the cursor is still tiny - but only when launching from the appImage. I also download the latest source and compiled it from scratch and it works correctly - with a larger cursor.
from librecad.
...having said that - I may have introduced something I shouldn't have - I compiled LC with QT6 libraries. I extracted the AppImage and looked at the contents - it uses QT5 libraries.
from librecad.
No, we are using qt6 with qt6 compatibility modules. It's clear, if you check the workflow file : it's built with qmake6
from librecad.
from librecad.
I think you are looking at a wrong file.
You can run AppImage with the option "--appimage-mount" to mount at investigate.
from librecad.
I ran the AppImage with the option "--appimage-extract", "--appimage-mount" shows the same thing:
from librecad.
Let's keep tracking at issue #1787
from librecad.
Related Issues (20)
- Error: Import Error: error opening DXF/DWG file HOT 12
- Print Preview Toolbar not closing
- Please don't tag RC/pre releases with the same tag pattern as releases HOT 4
- Move and Copy commands should be two different commands HOT 6
- program startup error HOT 15
- Hatch and construction layer HOT 1
- Incorrect polyline "closed" property editing via properties dialog HOT 1
- Entry Point Not Found HOT 3
- LC_ActionLayersExport: Mark messages for translation
- Request to add a simple resize tool. HOT 13
- double free or corruption (out) HOT 2
- Crash due to Assert on Line Angle action (QT6) HOT 2
- Strange drawing painting in QT6-based version? HOT 2
- Error 50 in drawing header in AutoDesk Viewer HOT 2
- Crash during reading LFF fonts HOT 13
- MTEXT alignment is broken
- Weird Screen->Drawing coordinates mapping with shift (QT6, master) HOT 2
- Delete an overlapped node (vertex) HOT 2
- 從現有的線段創建聚合線指令 此功能能否框選所有的雲行線後一次全部連接 HOT 1
- Solid hatch does not cover some elements even if it is pushed to top with Order HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from librecad.