Recent

Author Topic: Some Properties to TPanel (so much needed)  (Read 327 times)

Gald

  • New Member
  • *
  • Posts: 12
Some Properties to TPanel (so much needed)
« on: October 25, 2020, 04:12:00 pm »
Actual:
BevelColor
BevelInner
BevelOuter
BevelWidth


Improved:
BevelInner
BevelInnerWidth
BevelInnerColor

BevelOuter
BevelOuterWidth
BevelOuterColor


There's only one Color and Width to both, Inner and Outer, so they are mixing together.
This little improvement will change everything!

---

An additional request is that we have BevelStyles bvLowered, bvNone, bvRaised and bvSpace.
Honestly, I can't see the difference between them. Sorry.  :-[

It's possible to add bvShadow and bvGlow?

Blaazen

  • Hero Member
  • *****
  • Posts: 2994
  • POKE 54296,15
    • Eye-Candy Controls
Re: Some Properties to TPanel (so much needed)
« Reply #1 on: October 25, 2020, 04:53:48 pm »
@ Honestly, I can't see the difference between them. Sorry.

They make different visual 3D effects in combination:

BevelOuterBevelInnerEffect
bvRaisedbvNoneraised box (default)
bvLoweredbvNonelowered box
bvRaisedbvLoweredraised frame
bvLoweredbvRaisedlowered frame

See also TBevel. It can draw simiral bevels but it is not a container.
Lazarus 2.1.0 r64115 FPC 3.3.1 r40507 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

Alextp

  • Hero Member
  • *****
  • Posts: 1153
    • UVviewsoft
Re: Some Properties to TPanel (so much needed)
« Reply #2 on: October 25, 2020, 05:56:04 pm »
So you suggest to add

BevelInnerWidth
BevelInnerColor

BevelOuterWidth
BevelOuterColor
?
I do not agree, they are very rarely needed, do this painting in OnPaint.

lainz

  • Hero Member
  • *****
  • Posts: 3800
  • Leandro Diaz
Re: Some Properties to TPanel (so much needed)
« Reply #3 on: October 25, 2020, 05:58:06 pm »
Create your own custom panel, is hard to modify old code that is supposed to work in a retro compatible way.
https://lainz.github.io/
Download LazPaint https://lazpaint.github.io/
Download BGRABitmap and BGRAControls https://github.com/bgrabitmap

Gald

  • New Member
  • *
  • Posts: 12
Re: Some Properties to TPanel (so much needed)
« Reply #4 on: October 25, 2020, 06:42:12 pm »
Quote
They make different visual 3D effects in combination

Okay, it seems to work only when BevelColor is clDefault.

Quote
See also TBevel. It can draw similar Bevels but it is not a container.

I saw that, but TBevel doesn't have colors while TShape doesn't have TopLine, BottonLine, LeftLine and RightLine, like a TBevel.
And like you said, it is not a container.

The real good thing should be a TPanel with:

BevelTopInner
BevelTopInnerWidth
BevelTopInnerColor

BevelTopOuter
BevelTopOuterWidth
BevelTopOuterColor

BevelLeftInner
BevelLeftInnerWidth
BevelLeftInnerColor

BevelLeftOuter
BevelLeftOuterWidth
BevelLeftOuterColor

BevelRightInner
BevelRightInnerWidth
BevelRightInnerColor

BevelRightOuter
BevelRightOuterWidth
BevelRightOuterColor

BevelBottomInner
BevelBottomInnerWidth
BevelBottomInnerColor

BevelBottomOuter
BevelBottomOuterWidth
BevelBottomOuterColor

I've made a quickie sample to demonstrate what I mean.

 

TinyPortal © 2005-2018