FLTK logo

[master] 3ba0904 - Use PR #507 by @ggarra13 to fix issue #85.

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.commit  ]
 
Previous Message ]Next Message ]

[master] 3ba0904 - Use PR #507 by @ggarra13 to fix issue #85. "ManoloFLTK" Sep 27, 2022  
 
commit 3ba09047e2c9a8d1d2567dd6e6e5c1a911bad6e1
Author:     ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>
AuthorDate: Tue Sep 27 14:48:22 2022 +0200
Commit:     ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>
CommitDate: Tue Sep 27 14:48:22 2022 +0200

    Use PR #507 by @ggarra13 to fix issue #85.

 src/Fl_Menu.cxx | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git src/Fl_Menu.cxx src/Fl_Menu.cxx
index 5841a10..f6718ee 100644
--- src/Fl_Menu.cxx
+++ src/Fl_Menu.cxx
@@ -530,6 +530,12 @@ void menutitle::draw() {
 
 void menuwindow::draw() {
   if (damage() != FL_DAMAGE_CHILD) {    // complete redraw
+    if ( box() != FL_FLAT_BOX && ( Fl::is_scheme( "gtk+" ) ||
+        Fl::is_scheme( "plastic") || Fl::is_scheme( "gleam" ) )) {
+      // Draw a FL_FLAT_BOX to avoid on macOS the white corners of the menus
+      fl_draw_box( FL_FLAT_BOX, 0, 0, w(), h(),
+                  button ? button->color() : color());
+    }
     fl_draw_box(box(), 0, 0, w(), h(), button ? button->color() : color());
     if (menu) {
       const Fl_Menu_Item* m; int j;
Direct Link to Message ]
 
     
Previous Message ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.