Recent

Author Topic: Weird: TATSynEdit: conversion error  (Read 3669 times)

EganSolo

  • Sr. Member
  • ****
  • Posts: 290
Weird: TATSynEdit: conversion error
« on: January 27, 2017, 07:04:12 am »
The statement
Code: Pascal  [Select][+][-]
  1. var
  2.   sizeSmall, sizeFull : Single;
  3.  ...
  4.   ATStringProc.cCharScaleFullwidth_Default:= sizeFull/sizeSmall;
  5.  

yields Error: Incompatible types: got "Single" expected "Word."

I get that error when compiling it on one computer but not on my laptop.
Both systems are on Laz 1.6.2 install. Same fpc version also.

Checked the package options on both system. They're the same. I didn't change them.
What else can I check?



AlexTP

  • Hero Member
  • *****
  • Posts: 2401
    • UVviewsoft
Re: Weird: TATSynEdit: conversion error
« Reply #1 on: January 27, 2017, 07:40:44 pm »
It was Real; now it Int, in 100 parts, percents.
Fixed;
tested
Code: Pascal  [Select][+][-]
  1.   ATStringProc.cCharScaleFullwidth_Default:= Trunc(sizeFull * 100 / sizeSmall);
  2.  
« Last Edit: January 27, 2017, 07:46:01 pm by Alextp »

AlexTP

  • Hero Member
  • *****
  • Posts: 2401
    • UVviewsoft
Re: Weird: TATSynEdit: conversion error
« Reply #2 on: January 27, 2017, 08:07:32 pm »
Pls next askings about bugs- on GHub "issues"..

EganSolo

  • Sr. Member
  • ****
  • Posts: 290
Re: Weird: TATSynEdit: conversion error
« Reply #3 on: January 27, 2017, 09:33:33 pm »
Sorry, Alex, I wasn't sure if it was a bug :)
Like I said, it compiled fine on one my systems but not the other, so I thought it must have been a problem with my setup.

But thanks for the quick reply. Much appreciated and yes, will use GHub to report bugs.

AlexTP

  • Hero Member
  • *****
  • Posts: 2401
    • UVviewsoft
Re: Weird: TATSynEdit: conversion error
« Reply #4 on: January 28, 2017, 12:34:46 am »
it was a bug: I changed part of code, in ifdef-linux, and not changed same part for ifdef-win32.

 

TinyPortal © 2005-2018