Lars Gullik Bjønnes wrote:
> | Hi!
> | I'm writing the reference dialog for the gtk frontend currently. For
> | the documents dialog I need a way to get the current buffer.
>>
> | Does somebody know how to do this?
> 
> No hints from the other frontends?

It's as simple as:

namespace lyx {
namespace frontend {

class GReference : public GViewCB<ControlReference, GViewGladeB> {
public:
    void foo() {
        Buffer const & buffer = kernel().buffer();
    }
};

} // namespace frontend
} // namespace lyx

-- 
Angus

Reply via email to