Browse Source

init header title class

CPP-GTK4
yggverse 4 months ago
parent
commit
c8b7bef23c
  1. 1
      Makefile
  2. 27
      src/app/browser/header/title.cpp
  3. 36
      src/app/browser/header/title.h

1
Makefile

@ -11,6 +11,7 @@ SRCS = src/main.cpp\ @@ -11,6 +11,7 @@ SRCS = src/main.cpp\
src/app/browser/container/page.cpp\
src/app/browser/container/tab.cpp\
src/app/browser/header.cpp\
src/app/browser/header/title.cpp\
src/app/browser/menu.cpp
OBJS = $(SRCS:.cpp=.o)

27
src/app/browser/header/title.cpp

@ -0,0 +1,27 @@ @@ -0,0 +1,27 @@
#include "title.h"
namespace app
{
namespace browser
{
namespace header
{
// Construct
Title::Title(
Header *header
) {
// Init GTK
this->gtk = gtk_box_new(
GTK_ORIENTATION_HORIZONTAL,
Title::SPACING
);
gtk_widget_show(
GTK_WIDGET(
this->gtk
)
);
}
}
}
}

36
src/app/browser/header/title.h

@ -0,0 +1,36 @@ @@ -0,0 +1,36 @@
#ifndef APP_BROWSER_HEADER_TITLE_H
#define APP_BROWSER_HEADER_TITLE_H
// Dependencies
#include "../header.h"
namespace app
{
namespace browser
{
class Header;
namespace header
{
class Title
{
public:
// GTK
GtkWidget *gtk;
// Defaults
const gint SPACING = 0;
// Dependencies
Header *header;
Title(
Header *header
);
};
}
};
};
#endif
Loading…
Cancel
Save