On Sun, Feb 22, 2009 at 19:16, <p...@laptop.org> wrote: > i promised simon on irc that i'd raise this on the sugar devel > list, so thanks for replying and reminding me. > > (to recap: my "legacy" activity would like to be able to present > help and documentation info to the user via the local browser.) > > s page wrote: > > p...@laptop.org wrote: > > > can someone remind me if there's any reasonable way for an > > > activity to display html help or documentation using Browse? > > > > > > normally i'd simply have the app run "firefox file:///path-to-file", > > > but that won't work. > > > > In candidate-800, Browse can view > > file:///home/olpc/Activities/Maze.activity/activity/activity-maze.svg , > > so you would think you could tell it to launch and show your HTML help. > > > > I dunno if Rainbow restricts one activity from launching another. > > i believe it does, which has always been the problem for doing what > i would like to do. > > i think what might be useful (if rainbow is to be accomodated) is > a minimal-functionality html viewer. i'd be okay, in my > activity, if the viewer didn't allow any off-page clicks or > scripts -- just html rendering. doesn't seem like that would > cause a security issue, would it?
Another possibility is for Sugar to provide a dialog similar to the object chooser and view source windows with the mozilla widget embedded there. What would people prefer? Thanks, Tomeu > paul > > > > Ignoring that, you would think you could run one activity from another > > using a) Python code, b) exec(), or c) DBus. > > a) I couldn't figure out Journal's Start/Resume code, it seems to reach > > into datastore and activityfactory, which ends up invoking DBus. > > > > b) From Terminal Activity you would think that > > sugar-activity -u 'file:///{PATH_TO_YOUR_ACTIVITY}/myhtml/help.html' > > would work, but I can't even get the sugar-activity exec line in > > Activities/Browse.activity/activity/activity.info to work. The > > connection between its BUNDLE_ID, ACTIVITY_ID, OBJECT_ID and an > > activity's metadata like service_name is a mystery to me. > > > > > are there any workarounds (like tricking the > > > file to be in the journal so that browse can see it, or something like > > > that? > > > > You could write code to display the HTML within your own activity... > > > > > how does the new pdf-in-browse trick work? > > > > From > > http://sayamindu.randomink.org/ramblings/2008/10/14/14th-october-2008/ , > > "Wrote a small PDF viewer tool with support for the Journal which is > > then used by mozplugger to show PDF files within Browse. (You can put > > the file in your journal if you like it)" > > > > I.e. he's taking code that displays PDFs and running it inside the > > browser as a plug-in. That seems unrelated to what you're trying to do. > > > > Disclaimer: I have written four lines of Python code and zero activities > ;-) > > -- > > =S Page > > =--------------------- > paul fox, p...@laptop.org > _______________________________________________ > Sugar-devel mailing list > Sugar-devel@lists.sugarlabs.org > http://lists.sugarlabs.org/listinfo/sugar-devel > _______________________________________________ Sugar-devel mailing list Sugar-devel@lists.sugarlabs.org http://lists.sugarlabs.org/listinfo/sugar-devel