Custom versus default layout: What is the reason for pixel differences?

Custom versus default layout: What is the reason for pixel differences?

121
Basic UserBasic User
121

    Jan 21, 2018#1

    On some of the settings, the results are slightly different. For example, look at the separator in the custom layout versus a default layout. The custom separator has more pixels. Why does this happen?

    custom.PNG (2.1KiB)
    dafault.PNG (2.17KiB)

      Jan 21, 2018#2

      I figured it out: only tab border and group separator are involved in those stylings, all the other border and shadow stylings cause aesthetic conflict. The layout customization settings of UE are nice, but the options seem excessive and disorganized at times. Oh well, at least I've got it looking good now.

      6,687587
      Grand MasterGrand Master
      6,687587

        Jan 22, 2018#3

        The ribbon structure is really interesting. It is defined by Microsoft's GDI+ library (from %SystemRoot%\winsxs\amd64_microsoft.windows.gdiplus_6595b64144ccf1df_1.1.7601.23894_none_145eb2808b8d6928\GdiPlus.dll being of version 6.1.7601.23894 in my case) and not by UltraEdit or IDM Computer Solutions, Inc. It is as follows from most outer respectively bottom on z-axis to most inner respectively top on z-axis on using Windows Classic desktop theme on Windows 7:
        1. Tab background – there is one pixel row of tab background below bottom tab border.
        2. Tab border
        3. Category background
        4. Group background – there is one pixel row of group background below bottom group border and one pixel column right to right group border.
        5. Group border – just on left and top side
        6. Group shadow – just on right and bottom side with being covered mainly at bottom side by group caption background gradient
        7. Group caption background gradient – first color bottom, second color top
        8. Group separator – only on right side
        It can be seen on attached image that drawing the borders is not always 100% right. This is definitely caused by not perfect code in the GDIPlus library.

        In general the size and position of graphic elements on Windows depend on used font and configured font size. Microsoft introduced the measurement unit DLU – dialog unit. After calculation of a width, height, x or y position in DLU (floating point), the result is converted to a pixel value (integer) which quite often results in a failure by one pixel. Extra code is needed to correct this one pixel failure caused by different rounding from DLU to pixel. It looks like Microsoft has not added extra code to avoid the one pixel failure in GDIPlus.dll version 6.1.7601.23894.

        What does the different result by one pixel cause in your case is hard to determine from the screen shots posted by you.

        Please note that there are also multiple looks defined in GDIPlus.dll, see Icons are blurred in Classic mode with 64-bit UltraEdit version 24 on Windows 10 for a list of available looks. A look define more than just different colors for the various elements. For example ID_VIEW_APPLOOK_WIN_2000 looks really different to ID_VIEW_APPLOOK_OFF_2007_BLACK.
        ribbon_structure.png (32.23KiB)
        Ribbon structure as defined by Microsoft and used in UltraEdit on Windows 7 with Windows Classic desktop theme.
        Best regards from an UC/UE/UES for Windows user from Austria

        121
        Basic UserBasic User
        121

          Jan 22, 2018#4

          Thanks for the detailed info. That's fascinating! Is there a particular reason why UE based their layout customization options on the GDI+ library? Especially if GDI+ has such imperfections, wouldn't UE be better off building their layout customization options through some other means?

          6,687587
          Grand MasterGrand Master
          6,687587

            Jan 23, 2018#5

            You would have to ask your questions IDM by email. I do not know the reasons leading to the decision using Microsoft's GDI+ library also used by Windows itself since Windows Vista (Windows Explorer) and by Microsoft Office since Office 2007 and many other native Windows applications with a ribbon user interface.
            Best regards from an UC/UE/UES for Windows user from Austria