# pkg-config --cflags gtkmm-3.0 |xargs -n1
讓客戶(hù)滿(mǎn)意是我們工作的目標(biāo),不斷超越客戶(hù)的期望值來(lái)自于我們對(duì)這個(gè)行業(yè)的熱愛(ài)。我們立志把好的技術(shù)通過(guò)有效、簡(jiǎn)單的方式提供給客戶(hù),將通過(guò)不懈努力成為客戶(hù)在信息化領(lǐng)域值得信任、有價(jià)值的長(zhǎng)期合作伙伴,公司提供的服務(wù)項(xiàng)目有:域名注冊(cè)、網(wǎng)站空間、營(yíng)銷(xiāo)軟件、網(wǎng)站建設(shè)、樂(lè)安網(wǎng)站維護(hù)、網(wǎng)站推廣。# pkg-config --libs gtkmm-3.0 |xargs -n2
然后,在CB中新建一個(gè)基于C++語(yǔ)言的項(xiàng)目,并打開(kāi)項(xiàng)目的Build options...
進(jìn)行以下配置:
1. Other compiler options
2. Linker settings
3. Search directories
3. Hello,Gtkmm#includeint main(int argc, char** argv)
{auto app = Gtk::Application::create(argc, argv);
Gtk::Window window;
window.set_title("Hello,Gtkmm..");
window.set_default_size(400,300);
return app->run(window);
}
4. 一個(gè)帶點(diǎn)擊事件的簡(jiǎn)單按鈕窗口#include#include#include#includeclass Buttons : public Gtk::Window
{public:
Buttons();
virtual ~Buttons();
protected:
//Signal handlers:
void on_button_clicked();
//Child widgets:
Gtk::Button m_button;
};
Buttons::Buttons()
{m_button.add_pixlabel("info.xpm", "cool button");
set_title("Pixmap'd buttons!");
set_border_width(10);
set_default_size(280,40);
set_position(Gtk::WIN_POS_CENTER);
m_button.signal_clicked().connect( sigc::mem_fun(*this, &Buttons::on_button_clicked) );
add(m_button);
show_all_children();
}
Buttons::~Buttons(){}
void Buttons::on_button_clicked()
{std::cout<< "The Button is clicked"<< std::endl;
}
int main(int argc, char *argv[])
{auto app = Gtk::Application::create(argc, argv, "org.gtkmm.example");
Buttons buttons;
//Shows the window and returns when it is closed.
return app->run(buttons);
}
你是否還在尋找穩(wěn)定的海外服務(wù)器提供商?創(chuàng)新互聯(lián)www.cdcxhl.cn海外機(jī)房具備T級(jí)流量清洗系統(tǒng)配攻擊溯源,準(zhǔn)確流量調(diào)度確保服務(wù)器高可用性,企業(yè)級(jí)服務(wù)器適合批量采購(gòu),新人活動(dòng)首月15元起,快前往官網(wǎng)查看詳情吧