I have the following situation, but I feel like I'm doing something wrong...
I used a interface for Field
according to this post. The Field
interface inherits from the Style
class and Field1, 2 and 3 inherit from the Field
interface. I want to construct a Label
object with a couple of different types of fields which each have their own styling. I'm not sure if I'm doing it the right way like this, especially because I get the following error when I try to compile: Type 'Style' in interface list is not an interface
My code:
public interface Field : Style
{
int Xpos { get; set; }
int Ypos { get; set; }
int Zindex { get; set; }
}
What is the best way to solve this?
EDIT
I know inheriting a class from an interface is impossible, but what would be the best approach here?