From koffice-devel Mon Jan 25 02:45:00 2010 From: "Dr. Robert Marmorstein" Date: Mon, 25 Jan 2010 02:45:00 +0000 To: koffice-devel Subject: Re: Specific API questions Message-Id: <201001242145.01631.robert () narnia ! homeunix ! com> X-MARC-Message: https://marc.info/?l=koffice-devel&m=126438755431601 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============0978569987==" --===============0978569987== Content-Type: multipart/signed; boundary="nextPart16887322.o7deyWA1Ed"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart16887322.o7deyWA1Ed Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable > Note that I just committed a change that the dataCenterMap is removed and > replaced by a resourceManager (formerly KoCanvasResourceProvider) >=20 This looks like a *VERY* nice API change. I'm looking forward to playing w= ith=20 it. > When the canvasController gets focus it is supposed to iterate over all t= he > dockers added to the mainwindow and dynamic cast it to a > KoCanvasObserver(Base), if it works then it will call setCanvas on it. >=20 Okay. That makes sense. I'm not sure why this wasn't happening in my code= =2E =20 I'll have to poke at it some more. > > 2. I would like to extend this so that the configuration elements > For an example see KWDocument::firePageSetupChanged > where the page number is updated. > I guess that somewhere in the libs/main/ there is code that alters the > properties and it should use a similar mechanism to put those properties = in > the inlineTextObjectManager() (if it exists) >=20 Yes, I think I'd figured out I need an inlineTextObjectManager. Figuring o= ut=20 how to get (the right) one has been the trick. I'll look at the example yo= u=20 pointed me to, which should help. > You likely want to get the KAction for that, which indeed requires a KoVi= ew > instance. > Not sure what the proper solution is, but you should use > KoCanvasBase::canvasWidget() > and then repeatedly call parentWidget() on that to get to the top. > One of those in the stack will likely correctly > qobject_cast(widget); > so you can use that. >=20 Hmm. More complicated than I expected, but it makes sense. I'd tried play= ing=20 with canvasWidget to get a KAction, but didn't realize I'd need to use=20 "parentWidget" too. =20 > Hope my additions help. > Apologies for the heavy refactoring in trunk that will likely mean you ne= ed > to change some of your code to compile again. The class renames I did > yesterday (KoDockFactory -> KoDockFactoryBase etc) come to mind. Not a problem. I'm glad to see the code evolve to provide new features and= =20 better API for development. I just hope I can make contributions that are= =20 worth the time you guys have invested helping me . . . I've been delighted with how friendly and welcoming the koffice community i= s. =20 Thanks so much for your help here. Robert --nextPart16887322.o7deyWA1Ed Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEABECAAYFAktdBa0ACgkQNb20gW6TTsuTdgCfWCLpqY5OhQZtMCQNyAYwfwZw hvcAn1CE2YIDDKyiMfFdD3EX6DekP9T/ =b5OU -----END PGP SIGNATURE----- --nextPart16887322.o7deyWA1Ed-- --===============0978569987== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ koffice-devel mailing list koffice-devel@kde.org https://mail.kde.org/mailman/listinfo/koffice-devel --===============0978569987==--