I need help to compile fpvectorial examples lazarus / 54-FPvectorial ---------------------------------------------------------------------- pfergiu · 2013-07-13 22:14 Hi all I'm new at Lazarus. I've tried to compile fpvectorial examples, but I had no luck with this. Then, I visited this link: http://wiki.freepascal.org/fpvectorial and there, I found this https://lazarus-ccr.svn.sourceforge.net/svnroot/lazarus-ccr Later, I got compilation errors until I found this link https://github.com/alrieckert/lazarus/blob/master/components/fpvectori al/fpvectorial.pas So, I downloaded this new version and some examples (i.e. fpvviewer) finally started to work. At least some parts of them. I'm wondering if there is any updated and compilable version of all this. I'm still fighting with some remaining errors. I'm specially interested in drawing SVG files. I'm using revision 41613 of Lazarus. Thanks in advance, pfergiu ---------------------------------------------------------------------- BigChimp · 2013-07-14 03:11 There's a lot of missing information: what exactly goes wrong,  FPC version used, operating system etc. See here http://www.catb.org/~esr/faqs/smart-questions.html#code and the link in my signature. That wiki page states fpvectorial code is included in Lazarus. Did you find it? ---------------------------------------------------------------------- pfergiu · 2013-07-14 03:43 Thanks for your quick answer, BigChimp. Sorry, I will read the rules before asking. Here you go the answers to your questions: FPC 2.6.2 Lazarus v1.0.10 Revision SVN 41613 i386-win32-win32/win64 Ok, I see now what you mentioned about the wiki page. My mistake. Thanks for your help. pfergiu ---------------------------------------------------------------------- BigChimp · 2013-07-14 04:18 @Pfergiu: rules, rules... it's more guidelines Thanks for the info. Hint: you can put your OS, FPC, Laz version in your forum signature so you don't have to remember to specify it Hope you can get fpvectorial working; if not, the forum is there to help... Thanks, BigChimp ---------------------------------------------------------------------- felipemdc · 2013-07-14 11:04 fpvviewer from subversion is compatible with the latest fpvectorial from the lazarus subversion repository (right now it is compatible with revisions above 41000 or something like that, but this is not a rule, if I make changes it might start working only with even newer revisions). You should download all files of the latest fpvectorial, not only fpvectorial.pas You can download all of lazarus from svn for example, then fpvectorial is in the folder lazarus/components/fpvectorial Or only download fpvectorial ---------------------------------------------------------------------- pfergiu · 2013-07-14 15:36 Thanks felipemdc and BigChimp for your help. I think I'm doing better now I'm working right now with SVG images, generated by inkscape (version 0.48.4 r9939) and trying to figure out why some images work fine with fpvectorial and others don't. ---------------------------------------------------------------------- pfergiu · 2013-07-17 03:26 Hi again. I been debugging the code of fpvectorial for understand how it works and I think I found a tiny improvement. If you are using milimiters in your svg file, the parser work fine, but if you don't, may be you can get random values for width and height. Is a minor change for function "StringWithUnitToFloat" of svgvectorialreader. function TvSVGVectorialReader.StringWithUnitToFloat(AStr: string): Single; var   UnitStr, ValueStr: string;   Len: Integer; begin   // Check the unit   Len := Length(AStr);   UnitStr := Copy(AStr, Len-1, 2);   if UnitStr = 'mm' then   begin     ValueStr := Copy(AStr, 1, Len-2);     Result := StrToInt(ValueStr);   end   else     Result := StrToInt(AStr); end; I hope this can help. Regards, pfergiu ---------------------------------------------------------------------- felipemdc · 2013-07-28 06:31 Hello, thanks for the change, but always provide changes as patches against the latest lazarus trunk from SVN. Instructions here: http://wiki.freepascal.org/Creating_A_Patch Your case shows very well why this rule exists: 1> It is not possible from your pasted code to see what you changed. If it was in a patch format I could easily see this. 2> The code which you mention has already changed a lot, so the provided improvement makes no sense in the latest code. This explains why patches should be made against the latest lazarus from subversion, not against release like our 1.0.10. There is a large difference between fixes releases and the latest trunk even if a fixes release was released today. Because fix releases do not contain all commits in lazarus trunk. ---------------------------------------------------------------------- pfergiu · 2013-07-28 21:50 Understood. Thank you.