Re: [sc-dev] Our plan to improve Calc functionality related tophonetic text

2007-08-17 Thread Loiseleur Michel
 On Fri, 2007-08-17 at 09:34 +0200, Daniel Rentz wrote:
 [...]

 I'd say first point is to implement/enable Ruby support in the Calc core
 :-)

 And the first question may be - where should that extra ruby (phonetic
 guide) string be stored?  A couple of possibilities:

 1) Store that in rtl::OUString.  Excel seems to embed the ruby data into
 strings, so this may ease the import/export from/to the Excel file
 format.  However, doing so will probably require refactoring of the ruby
 handling code in Writer and/or raise an eyebrow of the framework
 people. ;-)

-1. rtl::OUString is a general and wide-use class.

 2) Store that in ScStringCell.  This may be easier but string cells are
 used a lot, and most likely only a faction of them use phonetic guides
 under normal use cases.  So, adding another data member to ScStringCell
 may not be desirable.

-1. I agree with you.

 3) Store that as a cell attribute.  If I understand correctly, Writer
 uses this approach.

0. This solution seems correct, but only a faction of them use phonetic
guides, so I am not really for this one.


 4) Or maybe subclass ScStringCell to create ScRubyStringCell, and use an
 instance of that class to store the ruby text information when needed ?
 Just a wild idea, but could this work (maybe) ?
+1. It would not pollute any other class and could be transparent enough
for other parts of code.


 Any thoughts on this?

Well, there's already in OOo code Python, StarBasic and Java. Now I see
Ruby and R. I am starting to think (and hope) that there will be a day
when macros won't be limited to StarBasic but could be _natively_ in all
those languages. And yes, I know that you can already do that with
webservices and -headless mode, but it's not human user compliant yet.


My 2 cents,
Regards,
-- 
Michel Loiseleur


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sc-dev] Our plan to improve Calc functionality related tophonetic text

2007-08-17 Thread Takashi Nakamoto
Hello, Kohei,

  I'd say first point is to implement/enable Ruby support in the Calc core :-)
 
 And the first question may be - where should that extra ruby (phonetic
 guide) string be stored?  A couple of possibilities:

This is very annoying question. We have to choose one idea from
possible ideas, but we have not determined where we will make the
phonetic string stored in each cell. Each idea may have its good
points and bad points.

If you have any recommendation, don't hesitate to tell us. I think
this topic should be discussed with related developers including OOo
Spreadsheet team.

 1) Store that in rtl::OUString.  Excel seems to embed the ruby data into
 strings, so this may ease the import/export from/to the Excel file
 format.  However, doing so will probably require refactoring of the ruby
 handling code in Writer and/or raise an eyebrow of the framework
 people. ;-)

At the beginning of our project, this idea was the first choise, but
now we think this implmentation might be very difficult and seek for
better ideas.

That is because, if we changed OUString, many unexpected errors might
be raised. OUString is used commonly and widely in OOo source codes.
And, of course, refactoring code in Writer project would be
required. I don't want to do it :(

 2) Store that in ScStringCell.  This may be easier but string cells are
 used a lot, and most likely only a faction of them use phonetic guides
 under normal use cases.  So, adding another data member to ScStringCell
 may not be desirable.

Now Storing phonetic text in ScStringCell is the first choise
because it seems to be easier. I can understand your concerns but I
wonder what concrete problems would be raised by this approach? I
can't evaluate the bad effect of this idea correctly.

 3) Store that as a cell attribute.  If I understand correctly, Writer
 uses this approach.

Related to this idea, I think storing phonetic text as one attribute
of EditTextObject in ScEditCell is also a good idea. ScEditCell seems to
be used to store decorated text in a cell. So we can deal with
phonetix text as one attribute of a decoration attributes. It doesn't
have any bad effect on ScStringCell. EditTextObject seems to be a
common class, so we ought to craete newEditRubyTextObject class if
this idea is accepted.

However, through this change, most cells that just hold Japanese text
would be instances of ScEditCell. This is a waste of memory.

Anyway, I've not investigated that we can realize this idea yet. This
investigation maytake long time.

 4) Or maybe subclass ScStringCell to create ScRubyStringCell, and use an
 instance of that class to store the ruby text information when needed ?
 Just a wild idea, but could this work (maybe) ?

I think this is not a good idea. It would make String type cell have
4 different classes, ScStringCell, ScRubyStringCell, ScEditCell,
ScRubyEditCell. Switching routine that choose one class from the four
classes for creating an instance of a cell would be complex.

Regards,
--
 Japanese Native-Language project
 Good-Day Inc.
 Takashi Nakamoto

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sc-dev] Re: Inserting Images?

2007-08-17 Thread Eike Rathke
Hi Wojciech,

On Wednesday, 2007-08-15 23:15:33 -0400, Wojciech Gryc wrote:

 After playing around some more, I figured out the problem (dealt with
 getting the services correctly). Just to let everyone know, I added
 information on how to embed images in a Spreadsheet (rather than link to
 them) on the Calc API Programming wiki:
 
 http://wiki.services.openoffice.org/wiki/Calc_API_Programming#Graphics

That looks a bit cumbersome. What's wrong with
http://codesnippets.services.openoffice.org/Calc/Calc.InsertGfx.snip ?

  Eike

-- 
 OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer.
 SunSign   0x87F8D412 : 2F58 5236 DB02 F335 8304  7D6C 65C9 F9B5 87F8 D412
 OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
 Please don't send personal mail to this [EMAIL PROTECTED] account, which I use 
for
 mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] 
Thanks.


pgpXK5sakRnjc.pgp
Description: PGP signature


Re: [sc-dev] I have a question

2007-08-17 Thread Eike Rathke
Hi gaozm,

On Wednesday, 2007-08-15 14:08:12 +0800, gaozm wrote:

2. Input characters into any column,for example between a1 and a21 input 
 figures from 1 to 21
3.Select the whole column a1,data-filter-standard 
 filter,condition-smallest %; value-10; ok
 Result: It will show 3 rows.
 Somebody hopes it should show 2 rows.

2 values could be expected there..

 I want to know whether it is a bug and whether it is necessary to fix.I 
 hope you give me some advices.Thank you!

Please check if an issue already exists for this and create one if it
doesn't. Implementation is in sc/source/core/data/table3.cxx
ScTable::TopTenQuery(). Looks like the number of entries displayed needs
some rounding.

  Eike

-- 
 OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer.
 SunSign   0x87F8D412 : 2F58 5236 DB02 F335 8304  7D6C 65C9 F9B5 87F8 D412
 OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS
 Please don't send personal mail to this [EMAIL PROTECTED] account, which I use 
for
 mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] 
Thanks.


pgpo1LxPRFEHA.pgp
Description: PGP signature


Re: [sc-dev] Re: Exciting News

2007-08-17 Thread Leonard Mada

Hi,

Eike Rathke wrote:

Hi Leonard,

On Wednesday, 2007-08-15 23:04:55 +0300, Leonard Mada wrote:
  
be careful when pasting from the wiki, as the wiki-features required to 
insert a space between 2 braces, changing '[[' to '['_space_'['  which 
breaks the code. One has to convert back these double-braces.


Embed such code examples in pre tags instead of space-indenting
them. See correction I applied.

  Eik


I have improved the code even further: more descriptions and NO need to 
break any line. Everything fits now easily on one line.


Leonard -  Wojciech

I encountered a possible bug: I was NOT  able to import text/strings 
from the spreadsheet into R. This is useful to have the variable 
names/annotations in the output.


And a last question: in order to have a generalization of the 
3-dependent variables linear regression to 'n'-variables, I need a way 
to have dynamic output matrices, like:

{$OUT#C(_some_column_)R(y):C(_some_column_)R(y+length)} - _the_output_
e.g. len - length( _input_ )
{$OUT#G1:G(1+len)} - _some_output_

Is this achievable?

Thanks and keep the good work,

Leonard

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sc-dev] Re: Exciting News

2007-08-17 Thread Leonard Mada

Hi Wojciec,

I detected some further potential bugs:

Can you please look into the following code: [in the coding window]

1.) IF there is NO input from the spreadsheet first, the script won't run:
  e.g. {$OUT#E1}-HELLO WORLD
  or x-25
 {$OUT#E1}-{$BASE}

2.) for some reason, the PLOT command does NOT work on my installation. 
It crashes Webserv.


System: W2k SP4

R version 2.5.0 (2007-04-23)
i386-pc-mingw32

locale:
LC_COLLATE=English_United States.1252;LC_CTYPE=English_United 
States.1252;LC_MONETARY=English_United 
States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252


attached base packages:
[1] stats graphics  grDevices utils datasets  methods 
[7] base


I hope you can find  the culprit.

Many thanks,

Leonard

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]