File tree Expand file tree Collapse file tree 2 files changed +30
-2
lines changed
Expand file tree Collapse file tree 2 files changed +30
-2
lines changed Original file line number Diff line number Diff line change @@ -89,6 +89,7 @@ void __fastcall TStyleConverterApplication::Run()
8989 try
9090 {
9191 LStyle = Fmx::Styles::TStyleStreaming::LoadFromFile (LInputFileName);
92+ // RemoveAuthorInfo(LStyle);
9293 MemStream = new TMemoryStream ();
9394 Fmx::Styles::TStyleStreaming::SaveToStream (
9495 LStyle, MemStream, LStyleFormat);
@@ -99,4 +100,23 @@ void __fastcall TStyleConverterApplication::Run()
99100 delete LStyle;
100101 delete MemStream;
101102 }
102- }
103+ }
104+
105+ /* *
106+ * This method will remove author information from the style.
107+ * @param AObject A style object.
108+ */
109+ void __fastcall TStyleConverterApplication::RemoveAuthorInfo (Fmx::Types::TFmxObject* AObject)
110+ {
111+ for (int i = 0 ; i < AObject->ChildrenCount ; ++i)
112+ {
113+ TStyleDescription* LDescription = dynamic_cast <TStyleDescription*>(AObject->Children ->Items [i]);
114+ if (LDescription != NULL )
115+ {
116+ LDescription->Author = " " ;
117+ LDescription->AuthorURL = " " ;
118+ LDescription->AuthorEMail = " " ;
119+ break ;
120+ }
121+ }
122+ }
Original file line number Diff line number Diff line change 44// ---------------------------------------------------------------------------
55#include < System.hpp>
66// ---------------------------------------------------------------------------
7+ namespace Fmx
8+ {
9+ namespace Types
10+ {
11+ class TFmxObject ;
12+ }
13+ }
14+
715class PACKAGE TStyleConverterApplication : public System::TObject
816{
917 typedef System::TObject inherited; /* *< Our parent's definition. */
1018
1119private:
12-
20+ void __fastcall RemoveAuthorInfo (Fmx::Types::TFmxObject* AObject);
1321protected:
1422
1523public:
You can’t perform that action at this time.
0 commit comments