LookAndFeel()

Home Forums General Programming LookAndFeel()

Viewing 9 posts - 41 through 49 (of 49 total)
  • Author
    Posts
  • #43193
    atom
    Keymaster
      • Topics: 159
      • Replies: 2945
      • Total: 3104
      • ★★★★★

      I’m looking into this right now. There are two rectangle classes now Rectangle that is a based class and a RectangleFloat class that is a based class. But lua is not clever enough to cast between those types. So special methods need to exist.

      I’m adding a toInt() method to the Rectangle class right now.

      #43214
      zeoka
      Participant
        • Topics: 73
        • Replies: 466
        • Total: 539
        • ★★★

        Thanks Atom

        Anyway this is not an issue :

        jj = Path()

        jj:addRectangle((width * 0.5)-(width*0.04),(width * 0.5) – (width*0.13)-( (width-(width*0.16) )- (width * 0.5)) ,width*0.08,width*0.13)

        kk = jj:getBoundsTransformed(AffineTransform( AffineTransform .rotation (angle,(width * 0.5),(width * 0.5))))

        g:excludeClipRegion(Rectangle(kk:getX(),kk:getY(),kk:getWidth(),kk:getHeight()))
        I got it like that
        toType() or getSmallestIntegerContainer ( ) would be ok too

        The problem is all codes from paths don’t get the transformed points but “the smaller rectangle in the path” so i can’t do nothing from this rectangle
        Currently a Juce excludeClipRegionFromPath() could be nice for that
        I Wonder if there is other possibilities….

        Attachments:
        You must be logged in to view attached files.
        #43309
        zeoka
        Participant
          • Topics: 73
          • Replies: 466
          • Total: 539
          • ★★★

          hi

          I’ve an error at start up in “called when the panel has finished loading”

          Ctrlr give me an error message : h is a nil value and the timer fail

          but the look and feel is applied anyway
          if I do h:getPropertyString(“uiType”) then look and feel is not applied.

          I don’t see what happens

           lf = LookAndFeel()
          		 lf:setImplementation (lookAndFeelImpl)
                   for m = 0,183 
                    do h = panel:getModulatorWithProperty("vstIndex",m):getComponent()
                       e = h:getProperty("uiType")
                       if e  == "uiSlider"
          	  	   then h:setCustomLookAndFeel(lf)
                      end
                   end
                   timer:setCallback (1,RestMidCallback)
                   timer:startTimer(1,1000)
          #43312
          atom
          Keymaster
            • Topics: 159
            • Replies: 2945
            • Total: 3104
            • ★★★★★

            You might be going out of bounds, are you sure it’s 0 to 183 inclusive, maybe you overshot the numbering ?

            #43316
            zeoka
            Participant
              • Topics: 73
              • Replies: 466
              • Total: 539
              • ★★★

              Oh that’s this ! thank you

              Tried before but with propertyString instead of property…

              #43398
              zeoka
              Participant
                • Topics: 73
                • Replies: 466
                • Total: 539
                • ★★★

                Any chances to draw a circle truncated by a simple rectangle in a path ?

                knb_p1= Path()
                knb_p1:startNewSubPath(DEMI-(width*0.02),DEMI- (width*0.13)-((width-(width*0.235))- DEMI))
                knb_p1:lineTo(         DEMI-(width*0.02),DEMI-((width-(width*0.235))- DEMI) ) 
                knb_p1:lineTo(         DEMI+(width*0.02),DEMI-((width-(width*0.235))- DEMI) )
                knb_p1:lineTo(         DEMI+(width*0.02),DEMI- (width*0.13)-((width-(width*0.235))- DEMI))
                --knb_p1:adddArc (width*0.1,width*0.1,width- (width*0.2) ,width -  (width*0.2),6.4,6.1  ,false)
                knb_p1:closeSubPath ()

                not sure I can do a biiigg arc and must find the correct angle that “glue” my points

                I read at about big arc in juce class and tried but really understand what I do

                If the start point of arc doesn’t math my last point is the path working ?

                I tried to turn all the graphics that is performed and corrected the after objects that turning*2 also !! but my lights effects turn too so it’s dead by this way

                Edit:
                SOLVED

                #62601
                zeoka
                Participant
                  • Topics: 73
                  • Replies: 466
                  • Total: 539
                  • ★★★

                  Hi
                  i need to aplly l&f to fixed sliders
                  Please Atom can you implement them or may be not possible ?
                  my panel sleeps since i can’t get that

                  it was hard to design the vp9000 knob. i’ve exaggerated the 3d effect but i’m not happy with the tick yet but it’s another story…..

                  Attachments:
                  You must be logged in to view attached files.
                  #62604
                  atom
                  Keymaster
                    • Topics: 159
                    • Replies: 2945
                    • Total: 3104
                    • ★★★★★

                    What’s the problem here ? you should be able to apply the LF to anything ? It’s not working ? it’s crashing ?

                    #62608
                    zeoka
                    Participant
                      • Topics: 73
                      • Replies: 466
                      • Total: 539
                      • ★★★

                      the l&f is simply not applied to them. on the panel the l&f is applied to canvas

                      i think may be this is because they are not in the l&f implementation , i see slider ,combo , ect … nothing specific however not sure it needs

                    Viewing 9 posts - 41 through 49 (of 49 total)
                    • The forum ‘Programming’ is closed to new topics and replies.
                    There is currently 0 users and 194 guests online
                    No users are currently active
                    Forum Statistics
                    Threads: 2,495, Posts: 17,374, Members: 77,605
                    Most users ever online was 12 on January 22, 2019 3:47 pm
                    Ctrlr