[Google Wave APIs] HowTo: Make a robot create a new Wave (Python)

2009-10-10 Thread Daniel Faust

Hi,

I myself had trouble with this issue and saw that it was asked for
several times. I found the solution and want to share it, so here it
goes:

def OnBlipSubmitted(properties, context):
  doc = context.GetBlipById(properties['blipId']).GetDocument()
  text = doc.GetText()
  if text.find('/createWave') == 0:
_newWave   = robot_abstract.NewWave(context,
context.GetRootWavelet().GetParticipants())
_newWave.SetTitle(New Wave's Title)
_newRootBlipId = _newWave.GetRootBlipId()
_newRootBlip   = context.GetBlipById(_newRootBlipId)
_newDocument   = _newRootBlip.GetDocument()
_newDocument.AppendText(This is an additional Text)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: HowTo: Make a robot create a new Wave (Python)

2009-10-10 Thread Daniel Faust

Oh, right, and you need to add
__ from waveapi import robot_abstract __
to your file

On Oct 10, 9:24 am, Daniel Faust soundlin...@gmail.com wrote:
 Hi,

 I myself had trouble with this issue and saw that it was asked for
 several times. I found the solution and want to share it, so here it
 goes:

 def OnBlipSubmitted(properties, context):
   doc = context.GetBlipById(properties['blipId']).GetDocument()
   text = doc.GetText()
   if text.find('/createWave') == 0:
     _newWave       = robot_abstract.NewWave(context,
 context.GetRootWavelet().GetParticipants())
     _newWave.SetTitle(New Wave's Title)
     _newRootBlipId = _newWave.GetRootBlipId()
     _newRootBlip   = context.GetBlipById(_newRootBlipId)
     _newDocument   = _newRootBlip.GetDocument()
     _newDocument.AppendText(This is an additional Text)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: Embedding waves in MediaWiki from different wave servers

2009-10-10 Thread Micke Nordin

Which version of PHP are you using? I have been asking around, and one
possible answer I got from the MediaWiki mailing list was that you
were using PHP4, which is no longer supported by MediaWiki. Could that
be the case? You can check the installation requirements for MediaWiki
here:

http://www.mediawiki.org/wiki/Manual:Installation_requirements

/Micke

On 7 Okt, 23:40, Jack Park jackp...@gmail.com wrote:
 According to the original error message, it never got to that. I went
 so far as to put up a wave / tag with no id, hoping to provoke that
 error message. It never got there. Always failed on passing the wrong
 thing to $parser

 On Wed, Oct 7, 2009 at 2:06 PM, Micke Nordin mickew...@gmail.com wrote:

  The tic thing is definitely an error on my part though (check under
  Array do's and don'ts):

 http://se2.php.net/manual/en/language.types.array.php

  You dont think that it is that alone which is causing the problem?

  /Micke

  On 7 Okt, 22:07, Jack Park jackp...@gmail.com wrote:
  That may be so. I'm not a php hacker by any means; I just copy what
  seems to work. In two other parser extensions I have, there was no
  ''. Prior to removing it, I got the error suggested earlier in this
  thread. After removing it, no further repeat of that error, plus
  which, the darn thing started working. Sure, might be something to do
  with windoz php. I dunno.

  Jack

  On Wed, Oct 7, 2009 at 1:04 PM, Micke Nordin mickew...@gmail.com wrote:

   FYI the ampersand makes it so the parser object is passed by reference
   instead of being copied, so that is a part of PHP and not a typo:
  http://us3.php.net/references.pass

   That should definitly work and it is what is specified in the
  MediaWikidocs.

   I don't now what difference putting tics  around the arg values make
   (what kind of tics?), but I'll look in to it.

   /Micke

   On 7 Okt, 19:29, Jack Park jackp...@gmail.com wrote:
   Good question.
   I have two extensions that use the parser thus:

   function getAppletOutput( $input, $args, $parser )

   which contrasts with the wave function:
   function waveRender($input, $argv, $parser)  as copied directly from 
   the file.

   I just removed the ampersand to
   function waveRender($input, $argv, $parser)
   and now it's almost working. Now I get a flood of errors such as:

   Use of undefined constant id - assumed 'id' in
   C:\\Apache2.2\\htdocs\\mediawiki\\extensions\\GoogleWave\\GoogleWave.php
   on line 38,...

   I then went in and found all the arg[] values and put ticks around them.
   It's now working. Seems to take a long time to load my wave, and I now
   need to play with width, height, etc, but it appears to have been a
   few typos in GoogleWave.php that prevented it from working.

   Thanks
   Jack

   On Wed, Oct 7, 2009 at 1:24 AM, Micke Nordin mickew...@gmail.com 
   wrote:

I suspect there is something wrong with youMediaWikiinstallation and/
or your PHP installation as parameter 3 to waveRender is a reference
to the parser object, that should be sent by the parser hook (by
   MediaWiki, that is). I have no idea as to why this doesn't work
though... It is not surprising that you get no error message, because
the problem is that the functions of the extension doesn't get called
by the parser properly. Does other extensions with parser hooks work
properly? Try to install any one of these extensions and see if you
get the same error:

   http://www.mediawiki.org/wiki/Category:ParserFirstCallInit_extensions

/Micke
   snip
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] how to detect a new blip added to a wave?

2009-10-10 Thread twdarkflame

I'm probably doing something silly here, but I'm just trying to get my
bot to respond to a post.

I tried;

 for (Event e: bundle.getBlipSubmittedEvents()) {
   Blip blip2 = wavelet.appendBlip();
  TextView textView2 = blip2.getDocument();
  textView2.append(event=+e.getType().toString());

  if (e.getType() == EventType.BLIP_SUBMITTED) {

  Blip blip3 = wavelet.appendBlip();
  TextView textView3 = blip3.getDocument();
  textView3.append(Thats a good comment!5/10);
}


  if (e.getType() == EventType.WAVELET_BLIP_CREATED ) {
  Blip blip4 = wavelet.appendBlip();
  TextView textView4 = blip4.getDocument();
  textView4.append(Thats a good comment! 10/10);
}
}

And I get nothing at all

I also tried putting it in the
 for (Event e: bundle.getEvents()) {
...
}

loop and also nothing.

However,  if (e.getType() == EventType.WAVELET_PARTICIPANTS_CHANGED)
{
does trigger an response.
And so does bundle.wasSelfAdded() (which of course isnt in a loop).


So...what am I missing?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: how to detect a new blip added to a wave?

2009-10-10 Thread F. Andy Seidl

Make sure your robot has registered receive the BLIP_SUBMITTED event.
You capaibilities.xml file must specify that you want that event.
When you modify capabilities.xml, be sure to update the version number
in that file or the change will not take effect.

On Oct 10, 6:50 am, twdarkflame darkfl...@gmail.com wrote:
 I'm probably doing something silly here, but I'm just trying to get my
 bot to respond to a post.

 I tried;

  for (Event e: bundle.getBlipSubmittedEvents()) {
            Blip blip2 = wavelet.appendBlip();
               TextView textView2 = blip2.getDocument();
               textView2.append(event=+e.getType().toString());

               if (e.getType() == EventType.BLIP_SUBMITTED) {

                   Blip blip3 = wavelet.appendBlip();
                   TextView textView3 = blip3.getDocument();
                   textView3.append(Thats a good comment!5/10);
                 }

               if (e.getType() == EventType.WAVELET_BLIP_CREATED ) {
                   Blip blip4 = wavelet.appendBlip();
                   TextView textView4 = blip4.getDocument();
                   textView4.append(Thats a good comment! 10/10);
                 }
     }

 And I get nothing at all

 I also tried putting it in the
  for (Event e: bundle.getEvents()) {
 ...

 }

 loop and also nothing.

 However,  if (e.getType() == EventType.WAVELET_PARTICIPANTS_CHANGED)
 {    
 does trigger an response.
 And so does bundle.wasSelfAdded() (which of course isnt in a loop).

 So...what am I missing?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: how to detect a new blip added to a wave?

2009-10-10 Thread Smola

I'd also like to point out a couple things  First off, when you click
reply on any blip, the WAVELET_BLIP_CREATED event will fire, so you
will receive your good comment blip before any comment is even
made.  Secondly, use bundle.getEvents() as opposed to
bundle.getBlipSubmittedEvents() if you want to listen and test for ANY
event the client sends with the bundle.



On Oct 10, 6:50 am, twdarkflame darkfl...@gmail.com wrote:
 I'm probably doing something silly here, but I'm just trying to get my
 bot to respond to a post.

 I tried;

  for (Event e: bundle.getBlipSubmittedEvents()) {
            Blip blip2 = wavelet.appendBlip();
               TextView textView2 = blip2.getDocument();
               textView2.append(event=+e.getType().toString());

               if (e.getType() == EventType.BLIP_SUBMITTED) {

                   Blip blip3 = wavelet.appendBlip();
                   TextView textView3 = blip3.getDocument();
                   textView3.append(Thats a good comment!5/10);
                 }

               if (e.getType() == EventType.WAVELET_BLIP_CREATED ) {
                   Blip blip4 = wavelet.appendBlip();
                   TextView textView4 = blip4.getDocument();
                   textView4.append(Thats a good comment! 10/10);
                 }
     }

 And I get nothing at all

 I also tried putting it in the
  for (Event e: bundle.getEvents()) {
 ...

 }

 loop and also nothing.

 However,  if (e.getType() == EventType.WAVELET_PARTICIPANTS_CHANGED)
 {    
 does trigger an response.
 And so does bundle.wasSelfAdded() (which of course isnt in a loop).

 So...what am I missing?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: Creating some annotated text to append to a blip

2009-10-10 Thread Smola

Well it seems that this post has fallen by the wayside.  Fortunately,
another post was made that indeed assists me with this problem.  It
involves creating text, appending it, then annotating it.  It is
located at:

http://groups.google.com/group/google-wave-api/browse_thread/thread/eb334177c34c931f?hl=en

However, my original goal was the create a chunk of text PRE-ANNOTATED
and then append it to a blip.  Is this even possible right now??


On Oct 4, 11:16 pm, Smola callmesm...@gmail.com wrote:
 I simply cannot wrap my head around this problem!  I have done
 everything I can think of but I simply can't figure it out!  I'm sure
 it's an easy fix as well.  I am fairly new to Java but have a pretty
 good amount of experience of programming in general.

 Anyway, enough with the preface.  I want to detect that a blip has
 been submitted (which I can do) and then append some styled text on
 the end of the blip (on a new line).  I can append unstyled text
 easily with the append() method.  I can also use setAnnotations() to
 change some styles on the entire text of the blip.  But I can't figure
 out how to take some text, style it with colors or whatever, and then
 append it.  I read up on theStyledTextclass but that deals with bold/
 underlined, etc type styles it seems.  I also tried using TextView as
 a constructor to create an empty TextView type variable but, silly me,
 TextView is an interface and has no constructor.  So then I tried
 taking the TextView variable I got from blip.getDocument() and tried
 to delete() the contents and repopulate them but that didn't work
 because the delete() method returns void.  I feel ridiculous because
 this must have a very basic solution but I just can't find it.  I
 would really appreciate it if someone would help me out on this!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: how to detect a new blip added to a wave?

2009-10-10 Thread Paul Staab

do start with simple things:
have you registiered BLIP_SUBMITTED and WAVELET_BLIP_CREATED in the
capabillities.xml and changed its version-number?

On 10 Okt., 12:50, twdarkflame darkfl...@gmail.com wrote:
 I'm probably doing something silly here, but I'm just trying to get my
 bot to respond to a post.

 I tried;

  for (Event e: bundle.getBlipSubmittedEvents()) {
            Blip blip2 = wavelet.appendBlip();
               TextView textView2 = blip2.getDocument();
               textView2.append(event=+e.getType().toString());

               if (e.getType() == EventType.BLIP_SUBMITTED) {

                   Blip blip3 = wavelet.appendBlip();
                   TextView textView3 = blip3.getDocument();
                   textView3.append(Thats a good comment!5/10);
                 }

               if (e.getType() == EventType.WAVELET_BLIP_CREATED ) {
                   Blip blip4 = wavelet.appendBlip();
                   TextView textView4 = blip4.getDocument();
                   textView4.append(Thats a good comment! 10/10);
                 }
     }

 And I get nothing at all

 I also tried putting it in the
  for (Event e: bundle.getEvents()) {
 ...

 }

 loop and also nothing.

 However,  if (e.getType() == EventType.WAVELET_PARTICIPANTS_CHANGED)
 {    
 does trigger an response.
 And so does bundle.wasSelfAdded() (which of course isnt in a loop).

 So...what am I missing?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Uploading robot

2009-10-10 Thread JamesBrooks

(I'm using Python) I created an application through appspot.com -
tehgdbot, however tehgdbot.appspot.com does not load for me, thus my
robot is not doing anything.

Using the Google App Launcher Engine to Deploy my bot does not create
a capabilities.xml like stated on the tutorial page, nor is the /robot
folder with whatever information is stored in there.

I managed to get my tehgdbot.py to do image_url='http://teh.gd/appspot/
icon.png', however that's all that happens, I don't get any reply from
my robot when it joins the wave - nothing.

Any suggestions?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: Embedding waves in MediaWiki from different wave servers

2009-10-10 Thread Jack Park

PHP5: the apache dll is php5apache2_2.dll

On Sat, Oct 10, 2009 at 1:29 AM, Micke Nordin mickew...@gmail.com wrote:

 Which version of PHP are you using? I have been asking around, and one
 possible answer I got from the MediaWiki mailing list was that you
 were using PHP4, which is no longer supported by MediaWiki. Could that
 be the case? You can check the installation requirements for MediaWiki
 here:

 http://www.mediawiki.org/wiki/Manual:Installation_requirements

 /Micke

 On 7 Okt, 23:40, Jack Park jackp...@gmail.com wrote:
 According to the original error message, it never got to that. I went
 so far as to put up a wave / tag with no id, hoping to provoke that
 error message. It never got there. Always failed on passing the wrong
 thing to $parser

 On Wed, Oct 7, 2009 at 2:06 PM, Micke Nordin mickew...@gmail.com wrote:

  The tic thing is definitely an error on my part though (check under
  Array do's and don'ts):

 http://se2.php.net/manual/en/language.types.array.php

  You dont think that it is that alone which is causing the problem?

  /Micke

  On 7 Okt, 22:07, Jack Park jackp...@gmail.com wrote:
  That may be so. I'm not a php hacker by any means; I just copy what
  seems to work. In two other parser extensions I have, there was no
  ''. Prior to removing it, I got the error suggested earlier in this
  thread. After removing it, no further repeat of that error, plus
  which, the darn thing started working. Sure, might be something to do
  with windoz php. I dunno.

  Jack

  On Wed, Oct 7, 2009 at 1:04 PM, Micke Nordin mickew...@gmail.com wrote:

   FYI the ampersand makes it so the parser object is passed by reference
   instead of being copied, so that is a part of PHP and not a typo:
  http://us3.php.net/references.pass

   That should definitly work and it is what is specified in the
  MediaWikidocs.

   I don't now what difference putting tics  around the arg values make
   (what kind of tics?), but I'll look in to it.

   /Micke

   On 7 Okt, 19:29, Jack Park jackp...@gmail.com wrote:
   Good question.
   I have two extensions that use the parser thus:

   function getAppletOutput( $input, $args, $parser )

   which contrasts with the wave function:
   function waveRender($input, $argv, $parser)  as copied directly from 
   the file.

   I just removed the ampersand to
   function waveRender($input, $argv, $parser)
   and now it's almost working. Now I get a flood of errors such as:

   Use of undefined constant id - assumed 'id' in
   C:\\Apache2.2\\htdocs\\mediawiki\\extensions\\GoogleWave\\GoogleWave.php
   on line 38,...

   I then went in and found all the arg[] values and put ticks around 
   them.
   It's now working. Seems to take a long time to load my wave, and I now
   need to play with width, height, etc, but it appears to have been a
   few typos in GoogleWave.php that prevented it from working.

   Thanks
   Jack

   On Wed, Oct 7, 2009 at 1:24 AM, Micke Nordin mickew...@gmail.com 
   wrote:

I suspect there is something wrong with youMediaWikiinstallation and/
or your PHP installation as parameter 3 to waveRender is a reference
to the parser object, that should be sent by the parser hook (by
   MediaWiki, that is). I have no idea as to why this doesn't work
though... It is not surprising that you get no error message, because
the problem is that the functions of the extension doesn't get called
by the parser properly. Does other extensions with parser hooks work
properly? Try to install any one of these extensions and see if you
get the same error:

   http://www.mediawiki.org/wiki/Category:ParserFirstCallInit_extensions

/Micke
   snip
 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: Creating some annotated text to append to a blip

2009-10-10 Thread F. Andy Seidl

Take a look at TextView.appendMarkup().  This method lets you append
text containing marketup which is then converted to annotations for
you.

On Oct 10, 12:06 pm, Smola callmesm...@gmail.com wrote:
 Well it seems that this post has fallen by the wayside.  Fortunately,
 another post was made that indeed assists me with this problem.  It
 involves creating text, appending it, then annotating it.  It is
 located at:

 http://groups.google.com/group/google-wave-api/browse_thread/thread/e...

 However, my original goal was the create a chunk of text PRE-ANNOTATED
 and then append it to a blip.  Is this even possible right now??

 On Oct 4, 11:16 pm, Smola callmesm...@gmail.com wrote:



  I simply cannot wrap my head around this problem!  I have done
  everything I can think of but I simply can't figure it out!  I'm sure
  it's an easy fix as well.  I am fairly new to Java but have a pretty
  good amount of experience of programming in general.

  Anyway, enough with the preface.  I want to detect that a blip has
  been submitted (which I can do) and then append some styled text on
  the end of the blip (on a new line).  I can append unstyled text
  easily with the append() method.  I can also use setAnnotations() to
  change some styles on the entire text of the blip.  But I can't figure
  out how to take some text, style it with colors or whatever, and then
  append it.  I read up on theStyledTextclass but that deals with bold/
  underlined, etc type styles it seems.  I also tried using TextView as
  a constructor to create an empty TextView type variable but, silly me,
  TextView is an interface and has no constructor.  So then I tried
  taking the TextView variable I got from blip.getDocument() and tried
  to delete() the contents and repopulate them but that didn't work
  because the delete() method returns void.  I feel ridiculous because
  this must have a very basic solution but I just can't find it.  I
  would really appreciate it if someone would help me out on this!- Hide 
  quoted text -

 - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] How to walk a blip hierarchy

2009-10-10 Thread F. Andy Seidl

Is is possible for a robot to walk the blip hierarchy in response to a
BLIP_SUBMITTED (or any other) event? I have tried a number of
experiments, but am still unclear on some things:

1) calling getRootBlip() does not always yeild a Blip that can be
accessed; is this true?
2) what is the relationship between inline blips and child blips?
Does Blip.getChildren() return inline blips?
3) is it the case that a robot simply cannot, in general, traverse all
the blips in a wavelet (perhaps, because the necessary metadata was
not included with the event and there is no API for accessing metadata
not provided with the event)?

Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: Creating some annotated text to append to a blip

2009-10-10 Thread Smola

Well I tried to do that actually.  I took a paragraph tag and tried to
append it with some styled text (just setting color to orange) and it
didn't work.  I've had other issues with that paragraph tag but
changing color shouldn't have been too much of a stretch.

Just for clarification the line of code was: text.appendMarkup(p
style=\color:orange;\Hello/p);

And it just appended plain black text to the end of my current
textview text.  Not even a new line.  But that's been discussed in a
different thread...;D


On Oct 10, 4:27 pm, F. Andy Seidl fase...@myst-technology.com
wrote:
 Take a look at TextView.appendMarkup().  This method lets you append
 text containing marketup which is then converted to annotations for
 you.

 On Oct 10, 12:06 pm, Smola callmesm...@gmail.com wrote:



  Well it seems that this post has fallen by the wayside.  Fortunately,
  another post was made that indeed assists me with this problem.  It
  involves creating text, appending it, then annotating it.  It is
  located at:

 http://groups.google.com/group/google-wave-api/browse_thread/thread/e...

  However, my original goal was the create a chunk of text PRE-ANNOTATED
  and then append it to a blip.  Is this even possible right now??

  On Oct 4, 11:16 pm, Smola callmesm...@gmail.com wrote:

   I simply cannot wrap my head around this problem!  I have done
   everything I can think of but I simply can't figure it out!  I'm sure
   it's an easy fix as well.  I am fairly new to Java but have a pretty
   good amount of experience of programming in general.

   Anyway, enough with the preface.  I want to detect that a blip has
   been submitted (which I can do) and then append some styled text on
   the end of the blip (on a new line).  I can append unstyled text
   easily with the append() method.  I can also use setAnnotations() to
   change some styles on the entire text of the blip.  But I can't figure
   out how to take some text, style it with colors or whatever, and then
   append it.  I read up on theStyledTextclass but that deals with bold/
   underlined, etc type styles it seems.  I also tried using TextView as
   a constructor to create an empty TextView type variable but, silly me,
   TextView is an interface and has no constructor.  So then I tried
   taking the TextView variable I got from blip.getDocument() and tried
   to delete() the contents and repopulate them but that didn't work
   because the delete() method returns void.  I feel ridiculous because
   this must have a very basic solution but I just can't find it.  I
   would really appreciate it if someone would help me out on this!- Hide 
   quoted text -

  - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] BlipSubmitted not working?

2009-10-10 Thread JamesBrooks

For some reason BlipSubmitted does not work, I've tried all sorts of
outputs when the method should be called.

tehgdbot.RegisterHandler(events.BLIP_SUBMITTED, OnBlipSubmitted)

def OnBlipSubmitted(properties, context):
blip = context.GetBlipById(properties['blipId'])
blip.CreateChild().GetDocument().SetText('I\'d now read the
text...')

But nothing...


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: BlipSubmitted not working?

2009-10-10 Thread James Purser

On Sat, 2009-10-10 at 18:34 -0700, JamesBrooks wrote:
 For some reason BlipSubmitted does not work, I've tried all sorts of
 outputs when the method should be called.
 
 tehgdbot.RegisterHandler(events.BLIP_SUBMITTED, OnBlipSubmitted)
 
 def OnBlipSubmitted(properties, context):
 blip = context.GetBlipById(properties['blipId'])
 blip.CreateChild().GetDocument().SetText('I\'d now read the
 text...')
 
 But nothing...

Have you tried putting some logging into the function?

logging.debug(OnBlipSubmitted Called) or something similar?
-- 
James Purser
Collaborynth
http://collaborynth.com.au
Mob: +61 406 576 553
Skype: purserj1977
Twitter: http://twitter.com/purserj


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: BlipSubmitted not working?

2009-10-10 Thread JamesBrooks

Nope, no debug added to the logs. I tried it with the
WAVELET_SELF_ADDED and it logged it, so it's something wrong with the
BLIP_SUBMITTED method?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: BlipSubmitted not working?

2009-10-10 Thread JamesBrooks

I've added you on Wave.

On Oct 11, 2:50 am, James Purser jamesrpur...@gmail.com wrote:
 On Sat, 2009-10-10 at 18:48 -0700, JamesBrooks wrote:
  Nope, no debug added to the logs. I tried it with the
  WAVELET_SELF_ADDED and it logged it, so it's something wrong with the
  BLIP_SUBMITTED method?

 Could you post your main function? Or if you're on the beta, my account
 is the same as my gmail.

 --
 James Purser
 Collaborynthhttp://collaborynth.com.au
 Mob: +61 406 576 553
 Skype: purserj1977
 Twitter:http://twitter.com/purserj
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] multiple wavelets per wave?

2009-10-10 Thread troyeb

Wavelets created with createwavelet() have the same waveletid
googlewaves.com!conv+root. Infact all wave/wavelets have this same
waveletid. The waveid is unique though. Is it possible to have
multiple wavelets per wave? According to api documentaion it should be.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Google Wave Web

2009-10-10 Thread Google İnvite

google waveweb page
no facebook

google wave
http://www.wave-google.us

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---



[Google Wave APIs] Re: How to walk a blip hierarchy

2009-10-10 Thread Jeremy

I tried to do this for a while and came to the conclusion that as of
now, the API does not supply a way to traverse the whole blip
hierarchy. The best thing I cam eup with was just storing the every
blip submitted. That way you at least have access to all the blips
submitted after the robot has joined the wave.

Hope that helps,
-Jeremy

On Oct 10, 3:36 pm, F. Andy Seidl fase...@myst-technology.com
wrote:
 Is is possible for a robot to walk the blip hierarchy in response to a
 BLIP_SUBMITTED (or any other) event? I have tried a number of
 experiments, but am still unclear on some things:

 1) calling getRootBlip() does not always yeild a Blip that can be
 accessed; is this true?
 2) what is the relationship between inline blips and child blips?
 Does Blip.getChildren() return inline blips?
 3) is it the case that a robot simply cannot, in general, traverse all
 the blips in a wavelet (perhaps, because the necessary metadata was
 not included with the event and there is no API for accessing metadata
 not provided with the event)?

 Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Wave API group.
To post to this group, send email to google-wave-api@googlegroups.com
To unsubscribe from this group, send email to 
google-wave-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-wave-api?hl=en
-~--~~~~--~~--~--~---