* * *

Author Topic: BGRA Controls v4.4  (Read 75295 times)

MISV

  • Full Member
  • ***
  • Posts: 244
Re: BGRA Controls v4.3.1.2
« Reply #240 on: May 26, 2017, 04:48:39 pm »
Great - then it sounds like Lazarus actually supports a very powerful skinning and styling solution :)

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.1.2
« Reply #241 on: May 26, 2017, 07:34:31 pm »
Great - then it sounds like Lazarus actually supports a very powerful skinning and styling solution :)

Try it then tell us how works for you.

I did my best on it.

jc99

  • Hero Member
  • *****
  • Posts: 516
    • My private Site
Re: BGRA Controls v4.3.1.2
« Reply #242 on: May 27, 2017, 12:45:44 am »
Hi, i just wanted to add the running-Lazarus-Cheeta (the logo.gif), an an animation, is there an easy way to add an Animated-gif ? e.G. in a TBGRASpriteAnimation ?
OS: Win XP x64, Win 7, Win 7 x64, Win 10, Win 10 x64, Suse Linux 13.2
Laz: 1.2 - 1.6.4, 1.8rc3
https://github.com/joecare99/public
'~|    /''
,_|oe \_,are

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.1.2
« Reply #243 on: May 27, 2017, 01:06:54 am »
Hi, i just wanted to add the running-Lazarus-Cheeta (the logo.gif), an an animation, is there an easy way to add an Animated-gif ? e.G. in a TBGRASpriteAnimation ?

TBGRASpriteAnimation

try this:

Code: Pascal  [Select]
  1. procedure AnimatedGifToSprite(Filename: string);

or if you store it as a resource call this:

Code: Pascal  [Select]
  1. LoadFromResourceName(Instance: THandle; const ResName: string);

Paul_

  • New member
  • *
  • Posts: 48
Re: BGRA Controls v4.3.1.2
« Reply #244 on: May 28, 2017, 08:29:16 pm »
There is one a little bit annoying thing, when you doubleclick BCButton component on form it launches Style manager instead of OnClick property like TButton.

MISV

  • Full Member
  • ***
  • Posts: 244
Re: BGRA Controls v4.3.1.2
« Reply #245 on: June 05, 2017, 03:01:56 pm »
Great - then it sounds like Lazarus actually supports a very powerful skinning and styling solution :)

Try it then tell us how works for you.

I did my best on it.

Will do - returning to it now.

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.1.2
« Reply #246 on: June 05, 2017, 03:30:01 pm »
Great - then it sounds like Lazarus actually supports a very powerful skinning and styling solution :)

Try it then tell us how works for you.

I did my best on it.

Will do - returning to it now.

Notice that's purely a skin, if you need to improve behaviour you need to modify Custom Drawn, not BGRAControls.

MISV

  • Full Member
  • ***
  • Posts: 244
Re: BGRA Controls v4.3.1.2
« Reply #247 on: June 05, 2017, 03:47:22 pm »
I very happy if controls/forms can get painted differently.

I am aiming for my software to have same look across platform - and preferably slightly unique look.

For now I reported a bug in Lazarus customdraw 1.6.4/Windows that prevents me from compiling
https://bugs.freepascal.org/view.php?id=31968

But installing your BGRA packages went well - will hopefully get around to testing later today :)


Awesome Programmer

  • Sr. Member
  • ****
  • Posts: 308
  • Programming is FUN only when it works :)
    • Cool Technology
Re: BGRA Controls v4.3.1.2
« Reply #248 on: June 08, 2017, 03:42:17 pm »
 :D Let me start by saying that whoever came up with the idea of writing and developing BGRA components is a GENIUS. I love all the components in BGRA. Thank you. In fact, I am able to use one of your component, BGRA Sprite animation successfully in my program. However, I am trying to use one of the other components in the BGRA tabs but not successful namely TBCButton.

What I am simply trying to do is incorporate TBCButton and enable its 3D polished and glossy look but running into problem. I can easily setup its skin during design time through style manager by double-clicking on button. However, I want to be able to do this while runtime programmatically or with my code, but I searched and searched for an answer there is seem to none. I selected the TBCButton and looked in its object inspector. It has style properties but only with two different options - bbtbutton and bbtdropdown.

So, how do you programmatically change the skin of the TBCButton? or Can you? If you can, could you please show me a sample code. Thank you.

I did ask a question related to this issue in the general section and got no reply. Here is the link to that question, which also has images attached to it. https://forum.lazarus.freepascal.org/index.php/topic,37108.msg248335.html#msg248335
« Last Edit: June 08, 2017, 03:46:41 pm by Awesome Programmer »

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.1.2
« Reply #249 on: June 08, 2017, 03:53:18 pm »
You can, check the demos, at least are two demos showing this how to.

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.2
« Reply #250 on: August 18, 2017, 04:27:35 pm »
BGRAControls v4.3.2.0
https://github.com/bgrabitmap/bgracontrols/releases

- PreserveGlyphOnAssign added, by default is on and prevents the glyph being replaced in any Assign call.
- BCImageButton toggle functionality: Now you can use it as 'toggle' button, and get/set pressed state.
- Using .lrs instead of .rc (bcpaperlistbox)
- published Constraints in bcbutton
- Added LoadFromBitmapResource overloaded method with less parameters
- Improved BCPaperListBox, now it has a property editor.

Notice the change on Assign, if this breaks your current code, just toggle PreserveGlyphOnAssign off in the object inspector.

josh

  • Sr. Member
  • ****
  • Posts: 437
Re: BGRA Controls v4.3.2
« Reply #251 on: September 15, 2017, 03:09:45 pm »
Hi
I am having a problem where BCLabel and BCButton is not displaying Russian, all I get is [][][][]....
A standard TLabel is displaying correctly when I select Eurostile or Gill San Font ( these are the 2 main ones I use), when i change fontex to same font; i get the above.

Development Installation Lazarus 1.3, FPC 2.7.1,Windows 7/8 32/64, OSX, *nix

Test Environment Lazarus & FPC Trunk on Windows and OSX (Cocoa Mainly on OSX). Testing also Crosscompile windows to OSX.. 
Any posts made from 2015 will be based on Lazarus Trunk.

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.2
« Reply #252 on: September 15, 2017, 07:39:27 pm »
Hi
I am having a problem where BCLabel and BCButton is not displaying Russian, all I get is [][][][]....
A standard TLabel is displaying correctly when I select Eurostile or Gill San Font ( these are the 2 main ones I use), when i change fontex to same font; i get the above.

Hi, that happens, for example, with TBCImageButton also?

Remember we're using BGRABitmap, maybe you can test this:
- Add a BGRAVirtualScreen
- Add OnRedraw event
- Write something with that font in that event, so we can see if BGRABitmap library can use that kind of fonts. If yes the problem is in the controls, if not the problem is with BGRABitmap.

josh

  • Sr. Member
  • ****
  • Posts: 437
Re: BGRA Controls v4.3.2
« Reply #253 on: September 15, 2017, 08:44:13 pm »
Hi Lainz,

Done some testing with other bgracontrols

Image attached
BCLabel
BCMaterialsDesignButton
BCImageButton.

So far BCImage Button is the only one which is showing the font and language correctly.
« Last Edit: September 15, 2017, 09:35:21 pm by josh »
Development Installation Lazarus 1.3, FPC 2.7.1,Windows 7/8 32/64, OSX, *nix

Test Environment Lazarus & FPC Trunk on Windows and OSX (Cocoa Mainly on OSX). Testing also Crosscompile windows to OSX.. 
Any posts made from 2015 will be based on Lazarus Trunk.

lainz

  • Hero Member
  • *****
  • Posts: 2082
Re: BGRA Controls v4.3.2
« Reply #254 on: September 16, 2017, 12:37:00 am »
Hi Lainz,

Done some testing with other bgracontrols

Image attached
BCLabel
BCMaterialsDesignButton
BCImageButton.

So far BCImage Button is the only one which is showing the font and language correctly.

Ok. That's strange, I did BCImageButton and BCMaterialDesignButton, and one works and the other doesn't works  :o
Sure is the text drawing function we're using, one different for each control.

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus