DevExpress
2013.07.08 11:00
스킨 목록을 가지고 오고 설정하는 방법
다물칸 주소복사
조회 수 1712 추천 수 0 댓글 0
구분 | 팁&트릭 |
---|---|
출처 | http://documentation.devexpress.com/#WindowsForms/CustomDocument14360 |
using DevExpress.XtraEditors;
using DevExpress.Skins;
// Handle the SelectedIndexChanged event to respond to selecting the skin name.
comboBoxEdit1.SelectedIndexChanged += new EventHandler(comboBoxEdit1_SelectedIndexChanged);
// Add available skin names to the combo box.
foreach(SkinContainer cnt in SkinManager.Default.Skins) {
comboBoxEdit1.Properties.Items.Add(cnt.SkinName);
}
//...
void comboBoxEdit1_SelectedIndexChanged(object sender, EventArgs e) {
ComboBoxEdit comboBox = sender as ComboBoxEdit;
string skinName = comboBox.Text;
DevExpress.LookAndFeel.UserLookAndFeel.Default.SkinName = skinName;
}
using DevExpress.Skins;
// Handle the SelectedIndexChanged event to respond to selecting the skin name.
comboBoxEdit1.SelectedIndexChanged += new EventHandler(comboBoxEdit1_SelectedIndexChanged);
// Add available skin names to the combo box.
foreach(SkinContainer cnt in SkinManager.Default.Skins) {
comboBoxEdit1.Properties.Items.Add(cnt.SkinName);
}
//...
void comboBoxEdit1_SelectedIndexChanged(object sender, EventArgs e) {
ComboBoxEdit comboBox = sender as ComboBoxEdit;
string skinName = comboBox.Text;
DevExpress.LookAndFeel.UserLookAndFeel.Default.SkinName = skinName;
}