@Override
	public void paint(Graphics g) {
		int w = getWidth();
		int h = getHeight();
		g.setColor(BG_COLOR);
		g.fillRect(0, 0, w, h);

		{
			int l_x = w-3*LOGO_SIZE/2;
			int l_y = h-LOGO_SIZE;
			int l_w = LOGO_SIZE * 2;
			int l_h = l_w;

			g.drawImage(logo, l_x, l_y, l_w, l_h, null);
			
		}

		int startY = TOP_MARGIN;

		{
			g.setColor(TITLE_COLOR);
			g.setFont(TITLE_FONT);
			FontMetrics fm = g.getFontMetrics();

			int titleStart = TOP_MARGIN + fm.getHeight();
			g.drawString(model.getTitle(), LEFT_MARGIN,
					titleStart);
			startY += fm.getHeight();
			
		}

		startY += Y_SPACING;

		{
			g.setColor(TEXT_COLOR);
			g.setFont(TEXT_FONT);
			FontMetrics fm = g.getFontMetrics();
			int nbrSize = 0;
			int nameSize = 0;
			int typeSize = 0;
			int annexSize = 0;
			for (Item i : agenda) {
				nbrSize = Math
						.max(nbrSize, fm.stringWidth(model.getParagraphSign() + i.getNumber()));
				nameSize = Math.max(nameSize, fm.stringWidth(i.getName()));
				typeSize = Math.max(typeSize, fm.stringWidth(i.getType()));
				annexSize = Math.max(annexSize, fm.stringWidth(i.getAnnex()));

			}

			int numberStart = LEFT_MARGIN;
			int nameStart = numberStart + nbrSize + X_SPACING;
			int typeStart = 0;
			int annexStart = 0;

			if (LEFT_MARGIN + RIGHT_MARGIN + nbrSize + nameSize + typeSize
					+ annexSize + X_SPACING * 3 < w) {
				typeStart = nameStart + nameSize + X_SPACING;
				annexStart = typeStart + typeSize + X_SPACING;
			} else {
				nameSize = w - LEFT_MARGIN - RIGHT_MARGIN - X_SPACING * 3
						- nbrSize - typeSize - annexSize;

				annexStart = w - RIGHT_MARGIN - annexSize;
				typeStart = annexStart - X_SPACING - typeSize;

			}

			int y = startY;

			for (Item i : agenda) {
				
				if (i.isAccepted()) 
					g.setColor(TEXT_COLOR);
				else 
					g.setColor(NOT_ACCEPTED_COLOR);
				
				if (agenda.isActive(i)) {
					int im_x = LEFT_MARGIN - IMAGE_SIZE - IMAGE_SPACING;
					int im_y = y - fm.getAscent() / 2 - IMAGE_SIZE / 2;
					g.drawImage(img, im_x, im_y, IMAGE_SIZE, IMAGE_SIZE, null);
				}

				g.drawString(model.getParagraphSign() + i.getNumber(), numberStart, y);
				g.drawString(i.getType(), typeStart, y);
				g.drawString(i.getAnnex(), annexStart, y);

				if (fm.stringWidth(i.getName()) > nameSize) {
					for (String row : splitString(i.getName(), fm, nameSize)) {
						g.drawString(row, nameStart, y);
						y += fm.getHeight() + Y_TEXT_SPACING;
					}
				} else {
					g.drawString(i.getName(), nameStart, y);
					y += fm.getHeight() + Y_TEXT_SPACING;
				}

			}

		}

	}