firemonkey

How to change the TTabItem's style

青春壹個敷衍的年華 提交于 2019-12-08 13:41:40
问题 Please take a look at the following picture: I need to modify color of blue bar at the TTabItem. But I did not find any place available for modification. Which attributes or styles can modify it? 回答1: to change look of tabitems you can design your custom style. Using TStyleBook component or Load an style to StyleBook and modify tabitemstyle on layout tree. You can watch this film to see how to manage styles properties. How to style buttons in Firemonkey with Delphi XE4 回答2: The answer by

C++ Builder bccarm error when calling std::vector::push_back with TObject descendant

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-08 13:41:32
问题 I have some simple C++ code which won't be compiled by the Clang based C++11 compiler bccaarm of C++ Builder 10.1 Berlin. This is the code: TComponent* Comp = new TComponent(this); std::vector<TComponent*> Comps; Comps.push_back(Comp); And this is the error: [bccaarm error] stl_iterator.h(963): rvalue reference to type 'value_type' (aka 'System: classes::TComponent * __strong') can not be bound to lvalue of type '__borland_class * isTObj __strong' (aka 'System::Classes::TComponent * __strong'

How to load large bitmap in FMX (fire monkey)

喜欢而已 提交于 2019-12-08 11:09:19
问题 I am trying to create a Manga viewer which needs to load JPG images with large sizes like 1000*16000, my application is in delphi FMX and i have already tried using TImage , TImageViewer , TImageControl but all of them use TBitmap which trims the size to 8192 after loading the image I tried searching for image libraries but i was unable to find anything for FMX (firemonkey) I was thinking maybe i could load the image in a Memory stream and then copy and draw it in smaller sizes to several

iOS notifications sporadic (FMX)

别说谁变了你拦得住时间么 提交于 2019-12-08 11:04:42
问题 Following the Embarcadero docs at this link i'm testing notifications on iOS (in FMX app built with C++). I've done the follownig: Added #include <System.Notification.hpp> to the header file Set FMLocalNotificationPermission to true Dropped TNotificationCenter component on the form Then, i put the following code in a button click: void __fastcall TForm1::ScheduleNotificationClick(TObject *Sender) { if (NotificationCenter1->Supported()) { TNotification *myNotification = NotificationCenter1-

move TRectangle with mouse (FMX, Win32)

十年热恋 提交于 2019-12-08 11:01:50
问题 I have an FMX form with a TLayout on it aligned to client. On the TLayout I have a TRectangle. I can move the TRectangle easily with the following code in a button click event: Rectangle1->Position->X = Rectangle1->Position->X + 10; Is there a clean way for me to do this (move the rectangle) with the mouse? Like click on the Rectangle and move it around to a new location? I'm just playing around trying to make a little drawing program to learn.... Using C++Builder 10.2 Version 25.0.29899.2631

How can I add a ListBoxItem programmatically?

雨燕双飞 提交于 2019-12-08 10:40:13
问题 I could only find how to create a ListBoxItem by clicking on the component -> Items Editor . How can we create programmatically a ListBoxItem using Firemonkey ? 回答1: Assuming that a ListBoxItem is an item of an existing TListBox component named ListBox1 , the item can be added like this: ListBox1.Items.Add('an item name'); an alternative: var id: Integer; . . . ListBox1.Items.AddObject('an item name', TObject(id)); EDIT Notice that this approach has to be considered valid only if the

Playing sound in firemonkey

依然范特西╮ 提交于 2019-12-08 10:40:11
问题 I use Firemonkey to deploy an android apps, with audio files on that. I have about 30 animal button, and each of button will heard animals sound when user select it. Here is my code for the first button: procedure TFMain.buttonLionClick(Sender: TObject); begin MediaPlayer1.FileName := 'D:\lion.mp3'; MediaPlayer1.Play; end; But it is failed. How can I deploying that sounds in to my apps? 回答1: First of all, if you want to build your app for android you need to convert the .mp3 to .3gp to be

Delphi FireMonkey iOS App: Error while Deploying to iPhone Simulator 8.1

不羁的心 提交于 2019-12-08 09:31:22
问题 I am working on a simple iOS App using Delphi FireMonkey. I am using Delphi XE7 in Virtual Windows 7 OS and a Mac OS with XCode 6.1 I have done the following steps: -> Activated the iOS Simulator as my target platform in the Project Manager. -> Created and activated a Connection profile for the OS X platform and the Test Connection is success. -> Added an SDK for iPhone Simulator 8.1 on the SDK Manager. -> paserver version 6.0.2.17 is running both in Mac OS and Windows OS. XCode is running on

Loading OpenSSL dynamic libraries arm & x86 (FMX, C++)

时间秒杀一切 提交于 2019-12-08 09:10:21
问题 I am able to use OpenSSL static libraries (libcrypto.a and libssl.a) in my iOS app thanks to this help. Now i can also use OpenSSL dynamic libraries (libcrypto.so and libssl.so) in my Android app version thanks to this info. I downloaded the files for Android in the OpenSSL_1.0.2g_Android.zip file from here. I just guessed and used the ARM files (armeabi-v7a folder) instead of the Intel files (x86 folder) and it worked on my Android test phone. My question: How do I make an Android build that

How to force Delphi to use D8.bat instead of dx.bat to compile Java 1.8 bytecode into DEX bytecode

北城余情 提交于 2019-12-08 07:20:51
问题 Today I faced a problem. My project needs to use some libraries (*.jar) that use Java 1.8 features. I see more and more libraries use now Java 1.8 features (like webRTC, exoplayer, etc.). In this way, we must do desugaring . Desugaring allows you to use these features on older devices by replacing new bytecodes and language APIs with older ones during the build process With d8.bat (replacement of dx.bat ), desugaring is turned on by default. So you can now use most of the latest language