title: onDraw not being called in custom view even though setWillNotDraw(false) is called
body: <p>So i have a custom view called Square which I want to add in a table.
  When I replace my squares with text views it works perfectly.</p>
  
  <p>I searched quite a bit online and found that I should call setWillNotDraw(false) in the constructor. I did this to no result. </p>
  
  <p>Here is my class Square:</p>
  
  <pre><code>public class Square extends View
  {
      private String courseName;
      private String className;
      private String place;
      private Weekdays weekday;
      private int hour;
      private Paint paint;
  
      public Square(Context context, AttributeSet attrs){
          super(context,attrs);
          setWillNotDraw(false);
      }
      public Square(Context context, String courseName, String className, String place, Weekdays weekday, int hour)
      {
          super(context);
  
          this.courseName = courseName;
          this.className = className;
          this.place = place;
          this.weekday = weekday;
          this.hour = hour;
  
          setWillNotDraw(false);
  
          paint = new Paint();
      }
  
      public Square(Context context,Weekdays weekdays, int i) {
          super(context);
          this.weekday = weekdays;
          this.hour = i;
  
          setWillNotDraw(false);
  
          paint = new Paint();
          paint.setColor(Color.BLACK);
      }
  
      @Override
      protected void onDraw(Canvas canvas)
      {       
          super.onDraw(canvas);
  
          canvas.drawText("Hello I'm a test", 1, 30, paint);
  
      }
      @Override
      protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
          super.onMeasure(widthMeasureSpec, heightMeasureSpec);
  
  
      }
  </code></pre>
  
  <p>I have tried setting the onMeasure() method to use 10,10 or whatever, but nothing shows up. I don't know if this is relevant to my problem. </p>
  
  <p>The table is made dynamically like this:</p>
  
  <pre><code>public class MainActivity extends Activity {
  
  private Controller controller;
  @Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
      controller = new Controller(this);
  
      createTable();
  
  }
  
  
  private void createTable() {
  
       // get a reference for the TableLayout
      TableLayout table = (TableLayout) findViewById(R.id.tableLayout1);
  
      /**Create 8 rows*/
      for(int i=0;i&lt;Controller.TABLE_ROW_COUNT;i++){
          // create a new TableRow
          TableRow row = new TableRow(this);
  
           /** create 5 columns*/
          for(int j=0;j&lt;Controller.TABLE_COLUMN_COUNT;j++){
              Square sq = controller.tableModel.getSquare(Weekdays.values()[j], i);
              row.addView(sq, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
  
          }
          // add the TableRow to the TableLayout
          table.addView(row,new TableLayout.LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
  
      }
  
  }
  </code></pre>
  
  <p>Thanks!</p>