Clarion 10 – Is it possible to make the submenu arrow/chevron larger?

Hi,

I am converting a large application from Clarion 6.3 to Clarion 10 (Legacy templates).

The application uses a standard Clarion MENUBAR with many nested MENU structures, for example:

MENU('&Financieel'),USE(?Finad)
  MENU('&Systeem- + stamgegevens'),USE(?FinadSysteemStamgegevens)
    MENU('&Systeem'),USE(?FinadSysteemStamgegevensSysteem)
      ITEM('&Systeemgegevens'),USE(...)
      ...
    END
    MENU('&Grootboek'),USE(...)
    MENU('&Debiteuren'),USE(...)
    MENU('&Crediteuren'),USE(...)
  END
END

The submenu indicator shown at the far right of a MENU item is very small in Clarion 10. I would like to replace it with, or display it as, a larger and clearer > / chevron.

I am not looking to add an ICON to the left of the menu text. I specifically mean the submenu indicator on the right-hand side.

I found cxSubMenu in C:\Clarion10\LibSrc\win\CWINT.INT.

The comments in CWINT.INT show the popup layout as:

<cxItemLMargin> ...
<cxTextLMargin> <text> <cxTextRMargin> <cxSubMenu> <cxItemRMargin>

So cxSubMenu appears to define the space reserved for the submenu indicator. I searched the complete C:\Clarion10 tree for cxSubMenu, but CWINT.INT is the only occurrence, so the actual drawing code seems to be inside the Clarion runtime.

Does anyone know:

  1. Can the size or appearance of the standard submenu arrow be changed through IMenuStyle, MenuStyleManager, SYSTEM{PROP:MenuStyle}, SetMenuMetric() or another Clarion property?

  2. What exactly does changing cxSubMenu affect? Only the reserved width, or also the actual submenu arrow?

  3. Is there an undocumented MenuStyle setting for the submenu arrow?

  4. If not, has anyone successfully changed this arrow in a Clarion application without making the complete menu owner-drawn?

I would prefer to keep the existing standard Clarion MENUBAR/MENU structure, because this is a large application with hundreds of menu items.

Thanks!

No. The submenu indicator is drawing by Windows regardless whether memu is owner draw or not.

It’s a value used to calculate width of item returned in response to WM_MEASUREITEM. Windows adds some margin to the returned width. The RTL subtracts value of cxSubMenu from coordinate of the right item edge.

No.

Sounds, you set too large value for cxSubMenu. Once again, the Clarion RTL does not draw the submenu indicator itself. All the menus in Clarion are owner-draw. Look at the HowToABC\Browses example program. It applies MenuStyle settings. Here how submenu markers are shown in its menu:

Thanks Alexey, that makes it clear.

So if I understand correctly, cxSubMenu only affects the calculated width and Windows always draws the actual submenu indicator.

Do you know if there is a practical way in Clarion to suppress/clip the Windows submenu indicator and draw a larger > ourselves, without replacing the complete existing MENUBAR/MENU structure?

I found Windows examples using ExcludeClipRect() during WM_DRAWITEM to prevent Windows from drawing its submenu arrow afterwards. Have you ever tried something like that with Clarion’s owner-drawn menus?

Have you experimented with <dpiAware>true</dpiAware> in the manifest, just in case that might make a difference?

The Chevron on the right of the menu is a windows style setting and should be mirroring the windows theme and style of the desktop… Themes can be modified but it will mean affecting the user desktop settings.

Google Gemini response for DPI Aware.

Setting <dpiAware>true</dpiAware> tells Windows that your application handles its own scaling, meaning standard small menu icons default to 16x16 pixels at 100% scaling and automatically scale up based on the monitor’s DPI factor (e.g., 20x20 at 125%, 24x24 at 150%, or 32x32 at 200%).

How Menu Icon Scaling Works

  • 100% Scaling (96 DPI): Standard small menu/toolbar icons are 16x16 pixels.
  • Scaled Displays: Windows or your UI framework multiplies the base 16px size by the scaling factor (DPI / 96).
  • Raster vs. Vector: Providing high-resolution bitmaps, multiple explicit resource sizes (16, 24, 32, 48px), or vector/SVG icons prevents blurring caused by standard system bitmap stretching.

Thanks. Yes, the application is already DPI aware.

I use the following settings in the application manifest:

<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
<dpiAwareness xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">system</dpiAwareness>

I specifically added these DPI settings because otherwise parts of the Clarion application appear blurry. With these settings the complete application is rendered very sharp under Windows 11.

The menu text and menu item height are also sharp and correctly sized. However, the submenu indicators on the right are still very small compared to the menu text.

So

<dpiAware>true</dpiAware>

is already active, but unfortunately it does not make the submenu arrow/chevron any larger.

This also seems consistent with Alexey’s explanation that Clarion draws/measures the owner-drawn menu items, while Windows draws the actual submenu indicator on the right.

I would prefer to keep the current DPI settings because the application currently renders perfectly sharp. I’m therefore particularly interested in whether there is a way to make only the Windows-drawn submenu indicator larger or more clearly visible, without changing the existing Clarion MENUBAR/MENU structure.

I didn’t find a way to stop Windows from drawing submenu markers when I wrote styled menus.