View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0038268 | Lazarus | LCL | public | 2020-12-28 12:18 | 2021-01-24 10:53 |
Reporter | CudaText man_ | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | new | Resolution | open | ||
OS | Linux x64 Ubuntu 20.04.1 | ||||
Product Version | 2.1 (SVN) | ||||
Summary | 0038268: In Ubuntu, TLabel is painted cropped for chars 'jy' | ||||
Description | I see that CudaText plugin paints TLabel with 'jy' chars cropped. I see the same on simple demo - create new app - add one Label (with AutoSize=true) and caption='xyzjk'. - label is cropped (both ObjInspector in IDE + runtime) picture added. | ||||
Tags | No tags attached. | ||||
Fixed in Revision | |||||
LazTarget | |||||
Widgetset | GTK 2 | ||||
Attached Files |
|
related to | 0038211 | new | TLabel.autosize fails. Suse only! Since years. | |
has duplicate | 0038298 | resolved | Bart Broersma | TLabel: too small if AutoSize = true |
has duplicate | 0038327 | resolved | Juha Manninen | Gtk2: TLabel: Text is cropped |
|
|
|
Lazarus 2.1.0 r64285M FPC 3.2.1 x86_64-linux-gtk2 |
|
I have the same problem when using DrawText: uses LCLIntf,LCLType; procedure TForm1.FormPaint(Sender: TObject); var s: String; r: TRect; begin s := 'xyzjkyg'; r := rect(0,0,width,height); DrawText(Canvas.Handle, pchar(s),length(s), r,DT_NOPREFIX or DT_SINGLELINE or DT_VCENTER or DT_END_ELLIPSIS); end; although canvas.TextRect(rect(0,0,width,height),100,100,s); works |
|
@CudaText man_ Is you graphic subsystem XOrg or Wayland? i've seen text cropping in GTK2 on Debian 11 Wayland. |
|
Mine is XOrg |
|
Can not reproduce on Debian 10.7, Xorg, Intel® HD Graphics 520 (Skylake GT2) Package: libgtk2.0-0 Version: 2.24.32-3 |
|
Mine is X.Org. |
|
@Alextpp @BeniBela gtk2 version? Xorg driver vendor? Did the host was restarted after last updates/upgrades (maybe fontcache corrupted)? If explicitly calling SelectFont before DrawText helps? If changing font from default helps? |
|
> gtk2 version? 2.24.32-4ubuntu4 Also: Lazarus 2.0.10 r55664M FPC 3.3.1 x86_64-linux-gtk2 >Xorg driver vendor? How do I check that? I have an RTX 2060 > If explicitly calling SelectFont before DrawText helps? Like this? SelectObject(canvas.handle, font.handle); No > Did the host was restarted after last updates/upgrades (maybe fontcache corrupted)? I restart it every day > If changing font from default helps? No At first the font size seems to help. But probably it always cuts off 2 or 3 pixels and those pixels have less impact at bigger size |
|
It looks like rectangle is of proper size, but text shifted down 2 pixels. Maybe these problems already fixed in trunk |
|
The DrawText issue also happens in trunk |
|
What font is default in your desktop? If explicitly specified 'Arial' or 'FreeSans' reproduce the problem? |
|
>What font is default in your desktop? Noto Sans, 12 >If explicitly specified 'Arial' or 'FreeSans' reproduce the problem? Yes. the third/forth picture above are arial |
|
The bug appears in gtk2 not in qt5 on same system Tested on Linux Mint 20 Ulyana x86_64 Mate dektop |
|
Do removing DT_VCENTER flag helps? |
|
No Adding DT_NOCLIP helps, but I need clipping since the text might be wider than the box. (too bad there is no H-CLIP only option to disable V-CLIP) |
Date Modified | Username | Field | Change |
---|---|---|---|
2020-12-28 12:18 | CudaText man_ | New Issue | |
2020-12-28 12:18 | CudaText man_ | File Added: Screenshot from 2020-12-28 14-10-07.png | |
2020-12-28 12:28 | CudaText man_ | Note Added: 0127854 | |
2021-01-03 17:56 | Bart Broersma | Relationship added | has duplicate 0038298 |
2021-01-08 17:40 | Juha Manninen | Relationship added | has duplicate 0038327 |
2021-01-09 14:53 | Benito van der Zander | Note Added: 0128198 | |
2021-01-09 17:27 | Anton Kavalenka | Note Added: 0128206 | |
2021-01-14 17:21 | Benito van der Zander | Note Added: 0128320 | |
2021-01-15 09:25 | Anton Kavalenka | Note Added: 0128337 | |
2021-01-15 09:25 | Anton Kavalenka | File Added: Здымак экрана, 2021-01-15 11-24-20.png | |
2021-01-15 09:27 | Anton Kavalenka | Note Edited: 0128337 | View Revisions |
2021-01-15 09:28 | Anton Kavalenka | Note Edited: 0128337 | View Revisions |
2021-01-17 23:56 | CudaText man | Note Added: 0128392 | |
2021-01-18 07:34 | Anton Kavalenka | Note Added: 0128394 | |
2021-01-18 07:34 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 08:13 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 08:15 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 08:31 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 08:32 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 08:37 | Anton Kavalenka | Note Edited: 0128394 | View Revisions |
2021-01-18 16:57 | Benito van der Zander | Note Added: 0128397 | |
2021-01-18 16:57 | Benito van der Zander | File Added: 0.png | |
2021-01-18 16:57 | Benito van der Zander | File Added: 1.png | |
2021-01-18 16:57 | Benito van der Zander | File Added: arial.png | |
2021-01-18 16:57 | Benito van der Zander | File Added: arial-2.png | |
2021-01-18 17:14 | Benito van der Zander | Note Edited: 0128397 | View Revisions |
2021-01-18 18:42 | Anton Kavalenka | Note Added: 0128399 | |
2021-01-19 13:49 | Zeljan Rikalo | Relationship added | related to 0038211 |
2021-01-20 21:50 | Benito van der Zander | Note Added: 0128455 | |
2021-01-21 21:23 | Anton Kavalenka | Note Added: 0128472 | |
2021-01-22 01:34 | Benito van der Zander | Note Added: 0128477 | |
2021-01-22 08:17 | Sreejith kumar g | Note Added: 0128480 | |
2021-01-22 08:17 | Sreejith kumar g | File Added: Screenshot QT5.png | |
2021-01-22 08:17 | Sreejith kumar g | File Added: Screenshot GTk2.png | |
2021-01-24 08:15 | Anton Kavalenka | Note Added: 0128539 | |
2021-01-24 10:53 | Benito van der Zander | Note Added: 0128546 |