1 17 18 package helloworld.renderer; 19 20 import java.awt.*; 21 22 import Jmc.commonGui.*; 23 import Jmc.commonGui.loader.*; 24 import Jmc.baseGui.gui_fixedSize; 25 import Jmc.baseTools.*; 26 27 37 public class HwTableRenderer implements base_tableItemRenderer_if 38 { 39 52 public base_guiWidget_if pcmf_getRenderWidget(Object xToRender, int xRow, int xCol, base_table_if xTable) 53 { 54 base_appl_if l_appl = (base_appl_if)base_registredObject.pcmf_getObjByName(base_appl_if.MY_APPL); 56 base_image_if l_img = (base_image_if)base_registredObject.pcmf_getObjByName("root_icon"); 57 base_image_if l_img2 = (base_image_if)base_registredObject.pcmf_getObjByName("entry_icon"); 58 59 base_text_if l_text = l_appl.pcmf_getGuiObjFactory().pcmf_createText(l_appl.pcmf_getApplType(), xToRender.toString(), "-" + xToRender.toString(), l_appl); 61 62 if (xRow == 0) 64 { 65 l_text.pcmf_setFont(new base_fontDesc("ARIAL", 12, Font.BOLD)); 66 l_text.pcmf_setBorder(2); 67 l_text.pcmf_setFixedSize(130, 20, gui_fixedSize.FIX_SIZE); 68 l_text.pcmf_setIcon(l_img); 69 } 70 else 71 { 72 l_text.pcmf_setFont(new base_fontDesc("ARIAL", 12, Font.ITALIC)); 74 l_text.pcmf_setFixedSize(130, 20, gui_fixedSize.FIX_SIZE); 75 l_text.pcmf_setIcon(l_img2); 76 if (xRow % 2 == 0) 77 l_text.pcmf_setBgColor("#FFA000"); 78 else 79 l_text.pcmf_setBgColor("#A0A000"); 80 } 81 82 return (l_text); 83 } 84 85 } 86 | Popular Tags |