Question: How would someone solve such a problem with classes and type as least as possible code? 
Here is what I have

Base interface for everything

```
    class IWindow
    {
    public: 
        virtual void Refresh() = 0;
// another 100 virtual methods
// ...
    };

```

This interface is used inside a library that has no idea about the concrete implementation.

Here is a version of the concrete implementation

```
    class ConcreteWindow : public IWindow
    {
    public:
        void Refresh() override {}
/// the other 100 overridden methods 
    };

```

Now we have another interface that adds some additional methods and also used inside that library.

```
class IDBDetail : public IWindow
{
public:
    virtual void DoDetail() = 0;

};

```

and here is the main problem, when we create the concrete inmplementation for it

```
class IGDBDetailWrapper : public IDBDetail, public ConcreteWindow
{
public :
    void DoDetail() {}
};

```

of course the concrete class `IGDBDetailWrapper` is abstract as well because it doesn't implement those 100 methods, but I don't wanna do that, I'd like just to reuse the implementation from `ConcreteWindow`, they are all working with the same window handle but this won't compile of course. 

I can copy/paste those 100 methods from `ConcreteWindow` into `IGDBDetailWrapper`, but that's an overkill, cause I might have another 10 such new interfaces and concrete implementations. 

What other pattern can I use here that would help solve the question and not re-implement those 100 methods again and again?

Thx

Answer: 
You can use virtual inheritance. If we ignore fact should `IDBDetail` inherit from `IWindow` or not, we could use virtual inheritance to solve problem with current architecture:

```
    class IWindow
    {
    public: 
        virtual void Refresh() = 0;
// another 100 virtual methods
// ...
    };

    class ConcreteWindow : virtual public IWindow
    {
    public:
        void Refresh() override {}
/// the other 100 overridden methods 
    };

class IDBDetail : virtual public IWindow
{
public:
    virtual void DoDetail() = 0;

};

class IGDBDetailWrapper : public IDBDetail, public ConcreteWindow
{
public :
    void DoDetail() {}
};

```

Now compiler will use implementation for your 101 abstract method from `ConcreteWindow`
@bashrc is right, but it should be possible to solve the problem with virtual inheritance:

```
class ConcreteWindow : public virtual IWindow {...}

class IDBDetail : public virtual IWindow {...}

```

This Wikipedia article on [virtual inheritance](https://en.wikipedia.org/wiki/Virtual_inheritance) states the solution as well.