Order of Status Panel Panes at Runtime.

Home Forums Konopka Signature VCL Controls (formerly Raize Components) Order of Status Panel Panes at Runtime.

Viewing 3 reply threads
  • Author
    Posts
    • #1328
      Steve Gill
      Participant

        Hi Ray,

        I have recently discovered that sometimes the order of TRzStatusBar panes are changing at runtime.

        At design time they are in the order I want, but at runtime some panes change their order.

        The first pane is aligned to alClient, while all other panes are aligned to alRight.

        In the screenshot below, it shows the status bar at design time, and at run time you can see how two panes have swapped positions.

        Panes Swapped

        RAD Studio 10.2.3 Tokyo

        Regards,

        Steve

      • #1335
        Ray Konopka
        Keymaster

          The TRzStatusBar uses the standard alignment functionality built into the VCL. In older versions of Delphi, at design-time, there used to be situations where the actual position of the control can change if its left (or top) edge overlaps the left (or top) edge of another control as a result of the bounding size of the parent control changes to become too small.

          However, I don’t believe this is still true for more recent versions of Delphi. Is your app doing anything in code to position the controls, set constraints, restore form size, etc?

          I’ve tried to duplicate what you are describing, but so far I have not been able to.

          Ray

        • #1336
          Steve Gill
          Participant

            Hi Ray,

            The main form size and position are saved when the application closes, and then they are set when the application starts. There is no code that resizes the controls or sets constraints.

            The strange thing is, this is only happening to a new glyph pane I added. It’s not happening to the other panes which have been there for years.

            = Steve

          • #1337
            Steve Gill
            Participant

              Hi Ray,

              Ok, it seems to be related to the Autosize property of the 3 text panes. I recently changed the Autosize property for them to True.

              If I set the Autosize property for the Glyph pane to true then it maintains the correct position, but unfortunately this makes the Glyph pane too wide as it’s allowing space for a caption that isn’t used.

              I’ve worked out a solution. I set the Glyph pane’s Autosize to True at design time. At run time, at the end of FormActivate I set the Glyph pane’s Autosize to False and then set the width.

              = Steve

          Viewing 3 reply threads
          • You must be logged in to reply to this topic.