[TextEditor_mcc] Re: Floating point usage in mcc/HandleInput.c

  • From: Gunther Nikl <gni@xxxxxxxx>
  • To: texteditor_mcc@xxxxxxxxxxxxx
  • Date: Tue, 7 Jun 2005 14:37:37 +0200


> Thanks for you patch, I will try to apply it to the next upcoming verison
> of TextEditor.mcc.

  It looks like my replacement is wrong :-/ A better replacement for

     LONG delta = ((((double)visible)/6.0)+0.5); // round the value

  should be

     LONG delta = (visible + 3) / 6;

  (I added 5 before). However the old code has a different rounding but
  I don't think that matters.


Linux is only free if your time has no value
 - Jamie Zawinski
TextEditor ML   - http://www.freelists.org/list/texteditor_mcc
Listserver help - mailto:texteditor_mcc-request@xxxxxxxxxxxxx?Subject=HELP
Bugtracker......: http://sourceforge.net/tracker/?atid=731469&group_id=135025

Other related posts: