[Scilab-loc] Double value and single value in gui.pot
Sylvestre Ledru
sylvestre.ledru at inria.fr
Tue May 27 14:20:00 CEST 2008
Hmmm, after a quick look with Vincent C. (who is also on this mailing
list), we realize that, yes, 'MATRIX_OF_DOUBLE_DATATYPE' is badly
choose name in the source. It is causing confusion in the code.
We are going to rename it to something like
MATRIX_OF_REAL_OR_COMPLEX_DATATYPE
Any comments on this?
> To avoid mistake, use 'a real' if it really need a real, 'real
> matrix' if we need a real matrix or 'real or complex matrix' if we
> need a generic data.
Yep, we are reading all messages (you can imagine how sexy it is) and
changing thme.
Sylvestre
PS: I c/c the dev mailing list since it is border-line.
Le mardi 27 mai 2008 à 20:08 +0800, Yung-Jang Lee a écrit :
> If we ever trace the code, (for example GUI\sci_gateway\c
> \sci_delmenu.c)
>
> ------------------------------------------------------------------------------------------------------
> // Unset a Menu a Scilab Graphic Window
> if (VarType(1) != sci_matrix)
> {
> Scierror(999, _("%s: Wrong type for first input argument:
> Double value expected.\n"),fname);
> return FALSE;
> }
> GetRhsVar(1, MATRIX_OF_DOUBLE_DATATYPE, &nbRow, &nbCol,
> &stkAdr);
> ------------------------------------------------------------------------------------------------------
> 'Double value' always maps to 'MATRIX_OF_DOUBLE_DATATYPE' which means
> 'real or complex matrix' in Scilab. (Memory representation of
> variables or
> http://wiki.scilab.org/Localization_in_English_-_Standard_messages
> ).
>
> But if we follow the gui context then 'Double value' seems to mean 'a
> real' (I don't expect to read any complex value in GUI applications).
>
> The use of 'Double value' causes trouble in interpretation of the
> meaning, especially if coupled with the use of 'Single value' which
> means 1x1 matrix.
>
> To avoid mistake, use 'a real' if it really need a real, 'real
> matrix' if we need a real matrix or 'real or complex matrix' if we
> need a generic data.
>
>
> YungLee
>
> 2008/5/27 Shiqi Yu <shiqi.yu at gmail.com>:
> I think they are all means a double float point real
> scalar(1x1 matrix), but we can't replace them with 'real or
> complex matrix'.
> First, if we use 'matrix', users will input a MxN (M,N>1)
> matrix.
> Second, I think they must be real and can't be complex.
>
>
> 2008/5/27 Yung-Jang Lee <yjlee123 at gmail.com>:
>
>
> Hi all,
>
> In gui.pot , I found following different messages
>
> 'A double value expected',
> 'A double expected',
> 'Scalar value expected',
> 'A value expected',
> 'Single value expected'
>
> and they all means 'A real or complex'.
>
> I module gui, 'double value' means 'real or complex
> matrix', 'single value' means '1x1 matrix' and 'A..'
> also means '1x1 matrix' . Follow this way, we have
>
> 'A double vaule' == 'Single value' == 'A value'.
>
> I think this induce unnecessary mistake. It is better
> to replace 'double value' to 'real or complex matrix'
> or just 'matrix' in gui module.
>
> YungLee
>
>
>
>
> --
> Shiqi Yu
> Shenzhen Institute of Advanced Technology,
> Chinese Academy of Sciences.
> Homepage: http://yushiqi.cn
>
More information about the dev
mailing list