Jump to content
Fivewin Brasil

Fonte e Cor no Cabeçalho do xBrowse


jfaguiar

Recommended Posts

Olá de novo galera !!!

Utilizando o estilo de programação abaixo, como faço para definir a cor e o fonte do header ?

Obrigadoo.

DEFINE FONT oFontScr NAME "Ms Sans Serif" SIZE 10,10
DEFINE FONT oBold NAME "ARIAL" SIZE 0,-16 BOLD
DEFINE DIALOG oDlg FROM 01,01 TO 43,154 TITLE "Planilha de Preços de Vendas / Comissões" FONT oFONTSCR
   nWidthLb  := oDlg:nWidth()  * IF(oDlg:nWidth() < 411, 0.480009,0.489900)
   nHeightLb := HeightLb( oDlg:nHeight() ) -15 //  para 1 fileira de botoes -40 2 fileiras
   oBrw := TxBrowse():New(oDlg)   // xBrowse copiado de CadItinerarios()
   oBrw:nTop  := 8
   oBrw:nLeft := 4
   oBrw:nbottom := nHeightLb + 41
   oBrw:nRight:= nWidthLb + 3 // 6 em pixel


   oBrw:nColDividerStyle := LINESTYLE_LIGHTGRAY // LINESTYLE_BLACK por array
   oBrw:nRowDividerStyle := LINESTYLE_LIGHTGRAY // LINESTYLE_BLACK
   oBrw:nMarqueeStyle    := MARQSTYLE_HIGHLCELL
   oBrw:cAlias := Alias()
   oBrw:lAllowColSwapping   := .f.
   oBrw:lColDividerComplete := .t.
   oBrw:lHScroll            := .f.
   oBrw:lFastEdit           := .t.
   oBRW:nRowHeight:= 20
   oBRW:Font := oBold

   //
   aCols := oBrw:AddCol()
   oBrw:aCols[1]:bStrData     := { || TBTABPRECO->PRODUTO}
   oBrw:aCols[1]:cHeader      := "Produto"
   oBrw:aCols[1]:bClrEdit     := oBrw:bClrStd
   oBrw:aCols[1]:nWidth       := 430
   oBrw:aCols[1]:bClrStd      := { || { CLR_BLACK, CLR_YELLOW }}
   oBrw:aCols[1]:oDataFont    := oBold
   //
   aCols := oBrw:AddCol()
   oBrw:aCols[2]:bStrData     := { || TRANSF(TBTABPRECO->CUSTOPLUS-TBTABPRECO->CUSTO,"@E 999.99")}
   oBrw:aCols[2]:cHeader      := "Grd"
   oBrw:aCols[2]:nWidth       := 60
   oBrw:aCols[2]:bClrStd      := { || { CLR_CYAN,CLR_WHITE }}
   oBrw:aCols[2]:oDataFont    := oBold 
   //
   aCols := oBrw:AddCol()
   oBrw:aCols[3]:bStrData     := { || TBTABPRECO->CUSTO}
   oBrw:aCols[3]:cHeader      := "Custo"
   oBrw:aCols[3]:bClrEdit     := oBrw:bClrStd
   oBrw:aCols[3]:bOnPostEdit  := { | oCol, xVal, nKey | IF( nKey == VK_RETURN .OR. nKey == VK_TAB, (TBTABPRECO->CUSTO:= xVal,oBrw:Refresh()),) }
   oBrw:aCols[3]:nEditType    := EDIT_GET
   oBrw:aCols[3]:nWidth       := 70
   oBrw:aCols[3]:bClrStd      := { || { CLR_CYAN,CLR_WHITE }}
   oBrw:aCols[3]:cEditPicture := "999.99"
   oBrw:aCols[3]:oDataFont    := oBold
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...